ci(setup): Use my setup action (#111) #51
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: π½ CI | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- "**.ts" | |
- deno.lock | |
- .github/workflows/ci.yml | |
pull_request: | |
paths: | |
- "**.ts" | |
- deno.lock | |
- .github/workflows/ci.yml | |
jobs: | |
lint-check: | |
name: π§Ή Lint Check | |
runs-on: Ubuntu-Latest | |
steps: | |
- name: π Checkout Repository | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: π¦ Setup Deno with Cache | |
uses: 5ouma/utils/setup-deno-with-cache@main | |
- name: π§Ή Lint Check | |
run: deno lint | |
- name: π Lint the JSDoc | |
run: deno doc --lint ./src | |
format-check: | |
name: π Format Check | |
runs-on: Ubuntu-Latest | |
steps: | |
- name: π Checkout Repository | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: π¦ Setup Deno with Cache | |
uses: 5ouma/utils/setup-deno-with-cache@main | |
- name: π Format Check | |
run: deno fmt --check | |
type-check: | |
name: π Type Check | |
runs-on: Ubuntu-Latest | |
steps: | |
- name: π Checkout Repository | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: π¦ Setup Deno with Cache | |
uses: 5ouma/utils/setup-deno-with-cache@main | |
- name: π Type Check | |
run: deno check --doc ./src | |
test: | |
name: π§ͺ Test | |
runs-on: Ubuntu-Latest | |
steps: | |
- name: π Checkout Repository | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: π¦ Setup Deno with Cache | |
uses: 5ouma/utils/setup-deno-with-cache@main | |
- name: π§ͺ Run Tests | |
run: deno task test:ci | |
- name: βοΈ Upload Coverage | |
uses: codecov/codecov-action@015f24e6818733317a2da2edd6290ab26238649a # v5.0.7 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
- name: βοΈ Upload Test Results | |
if: ${{ !cancelled() }} | |
uses: codecov/test-results-action@9739113ad922ea0a9abb4b2c0f8bf6a4aa8ef820 # v1.0.1 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
dry-run-publish: | |
name: π¦ Dry Run Publish | |
runs-on: Ubuntu-Latest | |
steps: | |
- name: π Checkout Repository | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: π¦ Setup Deno with Cache | |
uses: 5ouma/utils/setup-deno-with-cache@main | |
- name: π¦ Dry Run Publish | |
run: deno publish --dry-run |