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

How to pass multiple parameters to markdownlint-cli? #18

Open
Guts opened this issue Sep 9, 2021 · 1 comment
Open

How to pass multiple parameters to markdownlint-cli? #18

Guts opened this issue Sep 9, 2021 · 1 comment

Comments

@Guts
Copy link

Guts commented Sep 9, 2021

When I write:

- name: markdownlint-github-pr-review
  uses: reviewdog/action-markdownlint@v0
  with:
    github_token: ${{ secrets.GITHUB_TOKEN }}
    fail_on_error: true
    filter_mode: added
    reporter: github-pr-review
    markdownlint_flags: content/**/*.md

It works.
But if I add ignore parameter, so it's failing:

- name: markdownlint-github-pr-review
  uses: reviewdog/action-markdownlint@v0
  with:
    github_token: ${{ secrets.GITHUB_TOKEN }}
    fail_on_error: true
    filter_mode: added
    reporter: github-pr-review
    markdownlint_flags: -i **/template_*.md content/**/*.md

it's not working? What am I missing?

@skarzi
Copy link
Member

skarzi commented Sep 18, 2021

Hi,

have you checked if direct call: markdownlint -i **/template_*.md content/**/*.md works like expected?
I think it's because of bash's glob expanding - it expands **/template_*.md before calling markodownlint CLI.
Could you can try to escape it (at least glob passed as -i argument)? This can be done like:

-i '**/template_*.md' 'content/**/*.md'

More information - https://github.com/igorshubovych/markdownlint-cli#globbing

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

2 participants