From d00d32d65e855c2b0d36da11ec034d3fe9b19e1f Mon Sep 17 00:00:00 2001 From: Burrito Date: Sun, 29 Dec 2024 17:30:53 +0800 Subject: [PATCH] Add GitHub check actions (#22) --- .github/workflows/check-format.yml | 20 ++++++++++++++++++++ .github/workflows/check-lint.yml | 20 ++++++++++++++++++++ .github/workflows/check-type.yml | 20 ++++++++++++++++++++ 3 files changed, 60 insertions(+) create mode 100644 .github/workflows/check-format.yml create mode 100644 .github/workflows/check-lint.yml create mode 100644 .github/workflows/check-type.yml diff --git a/.github/workflows/check-format.yml b/.github/workflows/check-format.yml new file mode 100644 index 0000000..8a9ee0c --- /dev/null +++ b/.github/workflows/check-format.yml @@ -0,0 +1,20 @@ +name: Check Format + +on: + push: + branches: ['main'] + pull_request: + branches: ['main'] + +jobs: + check: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v3 + with: + node-version: 'lts/*' + cache: 'npm' + - run: npm ci + - run: npm run check-format diff --git a/.github/workflows/check-lint.yml b/.github/workflows/check-lint.yml new file mode 100644 index 0000000..15294c0 --- /dev/null +++ b/.github/workflows/check-lint.yml @@ -0,0 +1,20 @@ +name: Check Lint + +on: + push: + branches: ['main'] + pull_request: + branches: ['main'] + +jobs: + check: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v3 + with: + node-version: 'lts/*' + cache: 'npm' + - run: npm ci + - run: npm run check-lint diff --git a/.github/workflows/check-type.yml b/.github/workflows/check-type.yml new file mode 100644 index 0000000..f780a03 --- /dev/null +++ b/.github/workflows/check-type.yml @@ -0,0 +1,20 @@ +name: Check Type + +on: + push: + branches: ['main'] + pull_request: + branches: ['main'] + +jobs: + check: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v3 + with: + node-version: 'lts/*' + cache: 'npm' + - run: npm ci + - run: npm run check-type