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

Exact path matching ignore path #59

Merged
merged 4 commits into from
Sep 3, 2022

Conversation

bi1yeu
Copy link
Contributor

@bi1yeu bi1yeu commented Apr 24, 2022

Fixes #58

Currently, to ignore files from being checked, you can use ignore_paths and ignore_names, but these inputs can't be used in combination to exclude specific files.

As an example, say you want to exclude the file ./folder_a/maybe_ignore.sh. Using ignore_paths: folder_a would ignore other files in that directory that shouldn't be ignored. Using ignore_names: maybe_ignore.sh would ignore files that share the same name as the target file, but which exist in other directories.

├── folder_a
│   ├── maybe_ignore.sh
│   └── dont_ignore.sh
└── folder_b
    └── maybe_ignore.sh

This change makes the ignore_paths input a little more expressive:

  • allows specifying a full path to a file like ./folder_a/maybe_ignore.sh
  • allows specifying a glob matcher like **/maybe_ignore.sh

I also added more tests for ignore_paths. And I removed testfiles/ignore/ignore.sh, which looked unused. I can add this back if it was being used as an implicit exclusion test.

action.yaml Show resolved Hide resolved
Copy link
Owner

@ludeeus ludeeus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks 👍

@ludeeus ludeeus merged commit 6096f68 into ludeeus:master Sep 3, 2022
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

Successfully merging this pull request may close these issues.

Ignore specific files?
2 participants