Mirror of textlint for pre-commit, created with pre-commit-mirror-maker.
Add this to your .pre-commit-config.yaml
- repo: https://github.com/david-mcdowell-ilw/mirrors-textlint
rev: '' # place the desired textlint git tag or commit SHA here, e.g., v14.7.1 or 3e178b4f806c4ed6709346090f9a5b445b3add3f
hooks:
- id: textlint
By default, textlint will run with no args provided.
To change arguments, override the args
option as follows:
hooks:
- id: textlint
args: ["--ignore-path", ".gitignore"]
For any textlint rules used, define these as additional dependencies in the hook, with the main package listed first.
- repo: https://github.com/david-mcdowell-ilw/mirrors-textlint
rev: v14.7.1
hooks:
- id: textlint
args: ["--config", ".github/linters/.textlintrc.json", "--fix", "--ignore-path", ".gitignore"]
additional_dependencies:
- textlint@14.7.1
- textlint-filter-rule-comments@1.2.2
- textlint-rule-terminology@5.2.12
In this example, the contents of .textlintrc.json are the following:
{
"plugins": {},
"filters": {
"comments": true
},
"rules": {
"terminology": true
}
}
Rules used in the above example:
A complete list of textlint rules is available at the textlint GitHub wiki