Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions .github/workflows/markdown-lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,19 @@ on:
pull_request:
paths:
- '**.md'
- 'book/**'
Comment thread
nwt marked this conversation as resolved.

jobs:
markdown-link:
markdown-lint:
Comment thread
nwt marked this conversation as resolved.
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Lint
run: make markdown-lint

- name: Spell check
run: pip install codespell && make -C book codespell

- id: setup-chrome
uses: browser-actions/setup-chrome@v2
with:
Expand All @@ -29,13 +33,13 @@ jobs:
fail_on_error: true
filter_mode: nofilter

- name: Inform Slack users of link check failures
- name: Inform Slack users of check failures
uses: tiloio/slack-webhook-action@v1.1.2
if: failure() && github.ref_name == 'main'
with:
slack_web_hook_url: ${{ secrets.SLACK_WEBHOOK_BRIMLABS_DOCS }}
slack_json: |
{
"username": "markdown-link",
"text": "Markdown link check failed: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
"username": "markdown-lint",
"text": "Markdown lint check failed: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
}
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ markdown-lint:
# CI performs these actions individually since that looks nicer in the UI;
# this is a shortcut so that a local dev can easily run everything.
test-ci: fmt tidy vet test-generate test-unit test-system test-heavy
$(MAKE) -C book codespell

clean:
@rm -rf dist
Expand Down
4 changes: 4 additions & 0 deletions book/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,7 @@ node_modules:

vet:
GOOS=js GOARCH=wasm go vet super-example/main.go

.PHONY: codespell
codespell:
git ls-files -c -o --exclude-standard | xargs codespell -S src/tutorials/prs.json
11 changes: 11 additions & 0 deletions book/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,17 @@ After editing any JavaScript or Go files run `make` in this directory.
This will update the Wasm file so playground examples use a version of
SuperDB built from Go source files in the local repository.

The docs are spell checked with [codespell](https://github.com/codespell-project/codespell).
Install it with Homebrew:
```sh
brew install codespell
```
then check your work with
```sh
make codespell
```
This also runs as part of `make test-ci` and in CI.

## Conventions

The following is an evolving set of style conventions we've adopted when
Expand Down
Loading