From 7ff7ad9d87b2338c0a14c12c79d7f879db12da65 Mon Sep 17 00:00:00 2001 From: Dmytro Tkachenko Date: Tue, 22 Oct 2024 21:49:18 +0300 Subject: [PATCH] Actions --- .gitea/workflows/demo.yaml | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/.gitea/workflows/demo.yaml b/.gitea/workflows/demo.yaml index e2b5163..ec5165e 100644 --- a/.gitea/workflows/demo.yaml +++ b/.gitea/workflows/demo.yaml @@ -6,6 +6,28 @@ jobs: Run-Build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - run: npm install - - run: npm run build \ No newline at end of file + - name: Checkout code + uses: actions/checkout@v3 + - name: Use Node.js 20.x + uses: actions/setup-node@v2 + with: + node-version: 20.11.0 + - name: Yarn cache + uses: actions/cache@v2 + id: yarn-cache + with: + path: | + ${{ steps.yarn-cache-dir.outputs.dir }} + node_modules + */node_modules + */*/node_modules + key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/yarn.lock') }} + restore-keys: | + ${{ runner.os }}-build-${{ env.cache-name }}- + ${{ runner.os }}-build- + ${{ runner.os }}- + - name: Build + uses: actions/checkout@v3 + run: | + yarn + yarn build