Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix visual selection #37

Open
joereynolds opened this issue Oct 4, 2017 · 1 comment
Open

Fix visual selection #37

joereynolds opened this issue Oct 4, 2017 · 1 comment

Comments

@joereynolds
Copy link

joereynolds commented Oct 4, 2017

This would be quite a good feature to have.
Fixing the entire file can often generate a noisy diff :(

Since php-cs-fixer depends on a file, a possible way to do this would be for Vim to save the visual selection into a file, php-cs-fixer that newly created file and then apply those changes back onto the original file.

Thoughts?

Thanks :D

@stephpy
Copy link
Owner

stephpy commented Nov 22, 2017

Indeed, php-cs-fixer accepts stdin but does not return a stdout with fixed content. So we can't do it with the buffer. We have to do it with a temp file ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants