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 }}