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

autocorrect --format touches files which it doesn't actually modify #2249

Closed
2 tasks done
petterikamppuririchie opened this issue Jun 19, 2018 · 0 comments · Fixed by #2257
Closed
2 tasks done

autocorrect --format touches files which it doesn't actually modify #2249

petterikamppuririchie opened this issue Jun 19, 2018 · 0 comments · Fixed by #2257
Labels
enhancement Ideas for improvements of existing features and rules.

Comments

@petterikamppuririchie
Copy link

New Issue Checklist

swiftlint autocorrect --format --path <mydir>

This command touches all files it sees, even when this doesn't result in any changes to the files. Without --format swiftlint doesn't touch files it doesn't change.

This is bad when the command is run as part of Xcode build. Xcode thinks the file has changed externally (which it hasn't), and I get into conflicts (Xcode asks whether to reload file or keep Xcode version, which is annoying).

Also, I haven't found documentation for --format.

So, am I doing it wrong or could --format be fixed so it doesn't touch files that don't need any modifications? Thanks!

@marcelofabri marcelofabri added enhancement Ideas for improvements of existing features and rules. and removed O:User labels Jun 24, 2018
dirtydanee pushed a commit to dirtydanee/SwiftLint that referenced this issue Jun 25, 2018
dirtydanee pushed a commit to dirtydanee/SwiftLint that referenced this issue Aug 14, 2018
sjavora pushed a commit to sjavora/SwiftLint that referenced this issue Mar 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Ideas for improvements of existing features and rules.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants