Skip to content

Commit cb5b962

Browse files
committed
Add NPM script 'dev-docs' and document its usage
1 parent dd7c609 commit cb5b962

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

docs/.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
_site
22
.sass-cache
33
.jekyll-metadata
4+
5+
# for the `npm run dev-docs` hack that creates a hard linked tree of release-source
6+
releases/dev

docs/CONTRIBUTING.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,15 @@ gem install bundler
2727
# install all dependencies
2828
bundle install --path vendor/bundle
2929

30-
# build the site
31-
bundle exec jekyll serve
30+
# build, serve and live-reload the site
31+
npm run dev-docs
3232
```
3333

3434
After that you can access the site at http://localhost:4000/
3535

36-
Unfortunately, you will not see the full `release-source` without a little
37-
fiddling, as the site is excluded from Jekyll. So just supply a little symbolic
38-
link like this from the `./docs` dir: `mkdir releases && ln -s $PWD/release-source releases/latest`
36+
Unfortunately, you will not see the full `release-source`, as the site is excluded from
37+
Jekyll, but we made a little hack to expose the currently worked-on version.
38+
You can check out the currently worked on release docs under [`/releases/dev/release`](http://localhost:4000/releases/dev/release).
3939

4040
## Linting of Markdown
4141

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
"test": "npm run test-node && npm run test-headless && npm run test-webworker",
4545
"check-dependencies": "dependency-check package.json --no-dev --ignore-module esm",
4646
"build": "node ./build.cjs",
47+
"dev-docs": "cd docs; cp -rl release-source releases/dev; npm run serve-docs",
4748
"build-docs": "cd docs; bundle exec jekyll build",
4849
"serve-docs": "cd docs; bundle exec jekyll serve --incremental --verbose --livereload",
4950
"lint": "eslint --max-warnings 99 '**/*.{js,cjs,mjs}'",

0 commit comments

Comments
 (0)