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

Feature Request: Add Ability to Set "cache dir" in .erb-lint.yml #309

Open
klondikemarlen opened this issue Feb 11, 2023 · 3 comments
Open

Comments

@klondikemarlen
Copy link

I'd love to keep all the config in one place.
I'm already using the glob: option, and I'd love to be able to set the cache_dir as well.

e.g.
Instead of running bundle exec erblint --lint-all --cache --cache-dir tmp/xxx
I'd love to be able to set the cache and cache-dir options in the .erb-lint.yml config file.

@keithlayne
Copy link

Just to unnecessarily pile on, how bout a cache section in the config?

glob: ALLTHETHINGS
cache:
  enabled: true
  dir: cachey-mc-erblint-cache
linters: [] # linting overrated

@domingo2000
Copy link

I created a implementation for this in #351. My only concern with this is that currently the linter does not support running the cache with autocorrections, so if the option is set the users are not going to be able to autocorrect the linters because the cache option will not let them do it.

@klondikemarlen
Copy link
Author

klondikemarlen commented May 12, 2024

@domingo2000 That's awesome! Maybe just make it warn that cache is disabled when running with auto-correct?
i.e
"Cached disabled due to "autocorrect" option, will re-activate once no longer using "autocorrect" option."?

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

3 participants