Skip to content

Commit

Permalink
Add NPM script 'dev-docs' and document its usage
Browse files Browse the repository at this point in the history
  • Loading branch information
fatso83 committed Sep 27, 2023
1 parent dd7c609 commit cb5b962
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
3 changes: 3 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
_site
.sass-cache
.jekyll-metadata

# for the `npm run dev-docs` hack that creates a hard linked tree of release-source
releases/dev
10 changes: 5 additions & 5 deletions docs/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,15 @@ gem install bundler
# install all dependencies
bundle install --path vendor/bundle

# build the site
bundle exec jekyll serve
# build, serve and live-reload the site
npm run dev-docs
```

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

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

## Linting of Markdown

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

0 comments on commit cb5b962

Please sign in to comment.