Git Product home page Git Product logo

markdown-lint's People

Contributors

ahtierney avatar bzah avatar eldario avatar flamefire avatar gomzyakov avatar koppor avatar tarampampam avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

markdown-lint's Issues

Multiple files to ignore

Hello.

Is there an easy way how to exclude multiple files form the linting process?

Something like:

    - name: Lint changelog file
      uses: docker://avtodev/markdown-lint:v1
      with:
        ignore:
          - one_file.md
          - another_file.md
        args: '**.md'

^^^ This should recursively check all *.md files and skip two of them mentioned above.

Thank you

Github action fails but it succeeds locally

Describe the bug

Our github actions started failing even though we pin to version v1.3.1. An example is this PR: deliveryhero/helm-charts#120

But locally when I run the tool it doesn't complain:

$ docker run --rm -v "$PWD:/helm-charts" avtodev/markdown-lint:v1.3.1 --config /helm-charts/ci/markdown-lint.yaml /helm-charts/**/*.md
$ echo $?
0

Our config is here: https://github.com/deliveryhero/helm-charts/blob/master/.github/workflows/markdown-lint.yml
And here: https://github.com/deliveryhero/helm-charts/blob/master/ci/markdown-lint.yaml

If you look at the output here you can see it's like it's ignoring our config file.

This is new behaviour. Did something change recently?

Expected behaviour

Exit with no error and action is successful.

Actual behaviour

Actions are failing.

Steps to reproduce the behavior

Look at our PRs with failing actions but no markdown errors

Switch from markdownlint-cli to markdownlint-cli2

Is your feature request related to a problem?

markdown-lint supports configuration files per directory.

Example:

root directory

default: true
MD013: false

sub directory docs/decisions

default: true
MD013: false
MD024: false

When running on such a repository and a file in docs/decisions violates MD024, markdown-cli reports an error:

$ npx markdownlint-cli '**/*.md' --ignore node_modules
docs/decisions/0010-support-categories.md:103 MD024/no-duplicate-heading/no-duplicate-header Multiple headings with the same content [Context: "#### Examples"]
docs/decisions/0015-include-consulting-informed-of-raci.md:32 MD024/no-duplicate-heading/no-duplicate-header Multiple headings with the same content [Context: "### Include "Consulted" and "I..."]

Since this action is based on markdownlint-cli, it does not support multiple markdownlint configuration files - and thus also reports errors.

When running markdown-cli2, no error is reported:

$ npx markdownlint-cli2 "**/*.md" "#node_modules"
markdownlint-cli2 v0.4.0 (markdownlint v0.25.1)
Finding: **/*.md !node_modules
Linting: 31 file(s)
Summary: 0 error(s)

Describe the solution you'd like

Change from markdownlint-cli to markdown-cli2.

Additional context

Blog post on markdownlint-cli2: https://dlaa.me/blog/post/markdownlintcli2

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.