Closed vegidio closed 3 years ago
Hi, thanks for the issue. Does this occur when you launch command line swiftlint for your project?
Plugin, basically, runs swiftlint on a current file when it is changed, and parses the result. Before running SwiftLint I have to dump caches to the file system, because swiftlint command works with a file itself.
I will see what I can do, but answer will help me to narrow down my options.
Hi,
This is what I did to test:
Editor > Inspections > SwiftLint
and I also disabled the option Save files when switching to a different application
(this is enabled by default on Appcode), otherwise Appcode would save the file automatically for me when I switch to the terminal do run swiftlint
there.I made sure that my file watcher is configured to be triggered by external changes, done outside Appcode (second screenshot in my first message).
I opened the terminal, I went to the project's folder and I ran swiftlint
. I came back to Appcode and the File Watcher had not been triggered.
Before running SwiftLint I have to dump caches to the file system, because swiftlint command works with a file itself.
One suggestion: maybe your plugin could save the changes in a temporary file in the file system and run swiftlint
against this file? This way the original file will remain unaltered and the File Watcher will not be triggered.
Thanks a lot for the investigation. Will think what I can do with that.
Please check after updating to 1.13. Please check (update should be available after JB review)
I recently installed the SwiftLint plugin in AppCode and I noticed that when I turn on the code inspection
Editor > Inspections > SwiftLint
then the watcher that I created on my File Watcher for.swift
files is triggered automatically, as if the file is saved after every code inspection which is not the expected behaviorWhen SwiftLint inspection is off the File Watcher is not triggered.
This is my Inspections configuration:
And this is my File Watcher configuration: