From 2cae1842f7f7a248491bf961d7fd3f94c61a356c Mon Sep 17 00:00:00 2001 From: joonhang35 Date: Thu, 25 Jul 2024 11:44:30 +0800 Subject: [PATCH] commit CI --- .github/workflows/ci.yml | 46 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 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..a13d642 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,46 @@ +name: CI + +on: + push: + branches: + - main + - 'feature/*' + pull_request: + branches: + - main + +jobs: + build: + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [20.x] + + steps: + - name: Checkout code + uses: actions/checkout@v3 + + - name: Set up Node.js + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: 'yarn' + + - name: Install dependencies + run: yarn install + + - name: Run Lint + run: yarn lint + + - name: Run Tests + run: yarn test + + - name: Build project + run: yarn build + + - name: Upload build artifacts + uses: actions/upload-artifact@v3 + with: + name: build + path: .next/