-
Notifications
You must be signed in to change notification settings - Fork 9
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: setting to only lint files changed in the PR #35
Comments
Can you explain to me a bit what your use-case is for such feature? What I have seen from other GitHub Actions, these kind of features are not simple (as it depends a bit where you put the action in your workflow, and what type of workflow you are using). So, I rather not add such complexity to this action unless there is a good use-case for it :) If you can help me out to better understand what problem you trying to solve, I might be able to help you out with a solution. Tnx! |
My use case is based on work. When I open a PR, I care about the files I'm changing. I'm not going to fix N other unrelated files because there are errors even though the build/action will fail in this case. This is mostly an issue for newly linted (dirty) repos. Once things are in a good state, theoretically this would not be an issue going forward. |
Tnx, I understand what you are up against :) Yeah, in those cases it can be useful to only check a subset of files. I have looked around a bit what the options are, and basically, this action already supports enough to do this yourself (at least, I think so). That is to say, the Now there are actions like this: https://github.com/marketplace/actions/get-changed-files I think it is much better to do it like that, as that means this action doesn't need to complexity of figuring out what files changed; and it also doesn't make this action a jack-of-all-trades :D I haven't tested this as such, but I don't see why it shouldn't work. If you need further help building this, I can make a PoC for you if you like. And if you figure out how to do this in a workflow, I would love to see the result, so anyone else looking for it can use it. I might even mention it in the README (or you can make a Pull Request to add it as example in the README :D). Tnx, and let me know! |
hi @fearphage , Did you figure out how to do this? If there is anything I can help with, just let me know. Going to close this issue for now, as I think my suggestion will work very well, and is a lot cleaner. But if you get stuck or don't get it to work, just let me know, and I will see what I can do for you! Cheers! |
Your proposed solution should work. I haven't had a chance to try it. Thank you! |
Would be nice to limit linting to the current set of changed files.
The text was updated successfully, but these errors were encountered: