github-action-markdown-link-check
github-action-markdown-link-check copied to clipboard
Feature: Add exclude parameter
Hello
Would it be possible to add the exclude parameter, which will skip the checks for certain files?
- uses: gaurav-nelson/github-action-markdown-link-check@v1
with:
use-verbose-mode: 'yes'
config-file: 'mlc_config.json'
exclude: "CHANGELOG.md"
#or maybe better - set the find command parameters:
#exclude: '-not -path ./node_modules/*'
#exclude: '-not -name CHANGELOG.md'
Thank you
Thanks @ruzickap yes it makes sense. I'll take this one next.
@ruzickap I've had some success with replacing find with fd.
fd allows an .fdignore file https://github.com/sharkdp/fd#excluding-specific-files-or-directories
What do you think about not adding another option to exclude files and folder, instead recommending users to create an ./.fdignore file to skip specific files and folders?
I'm not sure if it's good idea to add some files (.fdignore) into the repository only to exclude the files during tests.
I would prefer to have variable and optionally .fdignore to exclude files from being "tested".
Maybe others have different opinion about it...
I would second that @ruzickap . The approach with .fdignore could lead to conflicts if another action also uses fd but you want to ignore (or not) different paths. Excluded files should preferably be limited to the individual action.
Thanks @ruzickap @musicEnfanthen for your inputs. I'll add it as a variable.
Hi,
Is this still planned to be added?
We are trying to use this action and we want to exclude one of the directories in our project but due to not being able to specify exclusions this makes us need to explicitly define the files and directories we want to use to avoid the undesired directory. This is not ideal as if there are new files and directories that contain .md files in the future one needs to remember adding it to the list which is easy to forget.
I would suggest adding a parameter to ignore a set of files, and a parameter to ignore a set of directories recursively. This is similarly to what's been done for inclusions.
Thank you