diff --git a/.gitea/workflows/demo.yaml b/.gitea/workflows/demo.yaml index b37f953..2d74f4d 100644 --- a/.gitea/workflows/demo.yaml +++ b/.gitea/workflows/demo.yaml @@ -22,6 +22,7 @@ jobs: Explore-Gitea-Actions: runs-on: ubuntu-latest steps: + # https://github.com/actions/checkout - name: Checkout code uses: actions/checkout@v4 - name: Get commit message (Push) @@ -73,12 +74,22 @@ jobs: env: PR_STATUS_FLAG: ${{ github.event.pull_request.merged }} - + # https://github.com/actions/setup-node 和 https://cicube.io/workflow-hub/github-action-setup-node/ + - name: nodejs + uses: actions/setup-node@v4 + with: + node-version: '22' + check-latest: true + cache: 'npm' + cache-dependency-path: '**/package-lock.json' + - name: Install dependencies + run: npm --version + - name: Run tests + run: echo "npm test 成功,actions/github-script@v5 创建合并请求" - run: echo "🎉 The job was automatically triggered by a ${{ gitea.event_name }} event." - run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by Gitea!" - run: echo "🔎 The name of your branch is ${{ gitea.ref }} and your repository is ${{ gitea.repository }}." - - name: Check out repository code - uses: actions/checkout@v4 + - run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner." - run: echo "🖥️ The workflow is now ready to test your code on the runner." - name: List files in the repository