Skip to content

Commit

Permalink
chore: typo-fix the docs in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
huitseeker committed May 2, 2022
1 parent e71cead commit 58d7900
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/actions/diffs/action.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
name: Detect Changes
description: Defines variables indicating the parts of the code that changed
outputs:
isDoc:
description: True when changes happened to some documentation
value: "${{ steps.diff.outputs.isDoc }}"
isRust:
description: True when changes happened to the rust code
value: "${{ steps.diff.outputs.isRust }}"
Expand All @@ -24,3 +27,7 @@ runs:
isExplorerClient:
- 'explorer/client/**'
- '.github/workflows/explorer-client-prs.yml'
isDoc:
- 'doc/**'
- '*.md'
- '.github/workflows/docs.yml'
31 changes: 31 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Documentation

on:
push:
branches: [ main, extensions ]
pull_request:
types: [opened, synchronize, reopened, ready_for_review]


jobs:
diff:
runs-on: [ubuntu-latest]
outputs:
isDoc: ${{ steps.diff.outputs.isDoc }}
steps:
- uses: actions/checkout@v3
- name: Detect Changes
uses: './.github/actions/diffs'
id: diff

spelling:
name: Lint documentation
needs: diff
if: needs.diff.outputs.isDoc == 'true'
runs-on: [ubuntu-latest]
steps:
- uses: actions/checkout@v3
- name: Spell Check Docs
uses: crate-ci/typos@master
with:
files: ./doc ./*.md

0 comments on commit 58d7900

Please sign in to comment.