|
35 | 35 | ts: ${{ steps.filter.outputs.ts }}
|
36 | 36 | k8s: ${{ steps.filter.outputs.k8s }}
|
37 | 37 | ci: ${{ steps.filter.outputs.ci }}
|
| 38 | + offlinedocs: ${{ steps.filter.outputs.offlinedocs }} |
38 | 39 | steps:
|
39 | 40 | - name: Checkout
|
40 | 41 | uses: actions/checkout@v3
|
|
53 | 54 | - "examples/web-server/**"
|
54 | 55 | - "examples/monitoring/**"
|
55 | 56 | - "examples/lima/**"
|
56 |
| - - "offlinedocs/**" |
57 | 57 | go:
|
58 | 58 | - "**.sql"
|
59 | 59 | - "**.go"
|
|
94 | 94 | ci:
|
95 | 95 | - ".github/actions/**"
|
96 | 96 | - ".github/workflows/ci.yaml"
|
| 97 | + offlinedocs: |
| 98 | + - "offlinedocs/**" |
| 99 | +
|
97 | 100 | - id: debug
|
98 | 101 | run: |
|
99 | 102 | echo "${{ toJSON(steps.filter )}}"
|
@@ -592,9 +595,46 @@ jobs:
|
592 | 595 | projectToken: 695c25b6cb65
|
593 | 596 | workingDir: "./site"
|
594 | 597 |
|
| 598 | + offlinedocs: |
| 599 | + name: fmt |
| 600 | + needs: changes |
| 601 | + runs-on: ${{ github.repository_owner == 'coder' && 'buildjet-8vcpu-ubuntu-2204' || 'ubuntu-latest' }} |
| 602 | + if: needs.changes.outputs.offlinedocs == 'true' || needs.changes.outputs.ci == 'true' |
| 603 | + steps: |
| 604 | + - name: Checkout |
| 605 | + uses: actions/checkout@v3 |
| 606 | + |
| 607 | + - name: Setup Node |
| 608 | + uses: buildjet/setup-node@v3 |
| 609 | + with: |
| 610 | + node-version: 16.20.1 |
| 611 | + cache: "yarn" |
| 612 | + cache-dependency-path: "offlinedocs/yarn.lock" |
| 613 | + |
| 614 | + - name: Install dependencies |
| 615 | + run: | |
| 616 | + cd offlinedocs |
| 617 | + yarn |
| 618 | +
|
| 619 | + - name: Check format |
| 620 | + run: | |
| 621 | + cd offlinedocs |
| 622 | + yarn format:check |
| 623 | +
|
| 624 | + - name: lint |
| 625 | + run: | |
| 626 | + cd offlinedocs |
| 627 | + yarn && yarn lint |
| 628 | +
|
| 629 | + - name: Build |
| 630 | + run: | |
| 631 | + version="$(./scripts/version.sh)" |
| 632 | + make -j build/coder_docs_"$version".tgz |
| 633 | +
|
595 | 634 | required:
|
596 | 635 | runs-on: ubuntu-latest
|
597 |
| - needs: [fmt, lint, gen, test-go, test-go-pg, test-go-race, test-js] |
| 636 | + needs: |
| 637 | + [fmt, lint, gen, test-go, test-go-pg, test-go-race, test-js, offlinedocs] |
598 | 638 | # Allow this job to run even if the needed jobs fail, are skipped or
|
599 | 639 | # cancelled.
|
600 | 640 | if: always()
|
|
0 commit comments