From 1f55f42734e0e808663d8f362ec9bf1f2cb6a870 Mon Sep 17 00:00:00 2001 From: Takeshi Kimata <117462761+kimatata@users.noreply.github.com> Date: Sun, 28 Jul 2024 10:33:23 +0900 Subject: [PATCH] feat: github actions (#22) --- .github/workflows/ci.yml | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..cedd16b --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,36 @@ +name: UnitTCMS CI + +on: + push: + branches: [ "main", "develop" ] + pull_request: + branches: [ "main", "develop" ] + +jobs: + unittcms-test: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [20.x] + + steps: + - uses: actions/checkout@v4 + + # root + - name: Format and unit test + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: 'npm' + - run: npm ci + - run: npm run format # prettier + - run: npm run test # vitest + + # frontend + - name: nextjs build + working-directory: ./frontend + run: npm ci + run: npm run build # nextjs build +