Skip to content

Commit

Permalink
chore(ci): add automatic link checking for markdown
Browse files Browse the repository at this point in the history
  • Loading branch information
drubin committed Nov 2, 2018
1 parent 4f34119 commit 9827b9e
Show file tree
Hide file tree
Showing 4 changed files with 117 additions and 4 deletions.
6 changes: 6 additions & 0 deletions bin/check-docs
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/bash -e

# linter before git check so we can lint docs even if they are 'dirty'
find docs -name '*.md' -type f -exec markdown-link-check {} \;

git diff --quiet HEAD -- docs/ || (echo 'generated docs are not up-to-date!' && exit 1)
2 changes: 1 addition & 1 deletion docs/reference/glossary.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Represents the current configuration and status of any running services in the [
inspected and modified via the Garden CLI's `environment` command.

Several named environment configurations may be defined (e.g. _dev_, _testing_, ...) in the [project's
`garden.yml`](../guides/configuration.md#project-configuration).
`garden.yml`](../using-garden/configuration-files.md#project-configuration).

#### Module
The basic unit of configuration in Garden. A module is defined by its
Expand Down
110 changes: 108 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
"husky": "^0.15.0-rc.13",
"lerna": "^3.0.4",
"lodash": "^4.17.11",
"markdown-link-check": "^3.7.2",
"shx": "^0.3.2",
"snyk": "^1.90.2",
"ts-node": "^7.0.1",
Expand All @@ -41,7 +42,7 @@
},
"scripts": {
"build": "npm run clean && gulp build",
"check-docs": "git diff --quiet HEAD -- docs/ || (echo 'generated docs are not up-to-date!' && exit 1)",
"check-docs": "./bin/check-docs",
"check-licenses": "gulp check-licenses",
"check-package-lock": "git diff --quiet HEAD -- package-lock.json || (echo 'package-lock.json is dirty!' && exit 1)",
"clean": "lerna run clean && git clean -X -f",
Expand Down

0 comments on commit 9827b9e

Please sign in to comment.