From 505fe19056b4393146c8befe54e77f88d38a046e Mon Sep 17 00:00:00 2001 From: laor <2680406465@qq.com> Date: Sat, 23 Dec 2023 21:49:38 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E4=BF=AE=E6=94=B9yml?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/main.yml | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 45f2b0f..34b5799 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -2,7 +2,7 @@ name: Publish And Deploy Demo on: push: branches: - - 'nuxt-realworld' + - nuxt-realworld jobs: build-and-deploy: @@ -11,29 +11,32 @@ jobs: # 下载源码 - name: Checkout - uses: actions/checkout@main + uses: actions/checkout@master - name: Change Dir run: cd 3.vue/5.server-render/nuxt-realworld # 打包构建 - name: SetUp nodejs - uses: actions/setup-node@main + uses: actions/setup-node@master # 安装pnpm - name: Install pnpm run: npm install -g pnpm # 安装依赖 - - name: Build Dep - - run: pnpm install - - run: pnpm run build - - run: tar -zcvf release.tgz .output ecosystem.config.js + - name: Install Dep + run: pnpm install + + - name: Build + run: pnpm run build + - name: Compress + run: tar -zcvf release.tgz .output ecosystem.config.js # 发布 Release - name: Create Release id: create_release - uses: actions/create-release@main + uses: actions/create-release@master env: GITHUB_TOKEN: ${{ secrets.TOKEN }} with: @@ -45,7 +48,7 @@ jobs: # 上传构建结果到 Release - name: Upload Release Asset id: upload-release-asset - uses: actions/upload-release-asset@main + uses: actions/upload-release-asset@master env: GITHUB_TOKEN: ${{ secrets.TOKEN }} with: @@ -56,7 +59,7 @@ jobs: # 部署到服务器 - name: Deploy - uses: appleboy/ssh-action@main + uses: appleboy/ssh-action@master with: host: ${{ secrets.HOST }} username: ${{ secrets.USERNAME }}