From 2c894d0ae2d410d15523835351352908e085ebec Mon Sep 17 00:00:00 2001 From: wenyutang-ms Date: Thu, 4 Jan 2024 15:43:31 +0800 Subject: [PATCH] build: trigger release pipeline daily and upload artifacts to pipeline --- .github/workflows/cd.yml | 27 ++++++++------------------- 1 file changed, 8 insertions(+), 19 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index a1af02fd..e3554bfb 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -1,42 +1,31 @@ name: "CD" on: - workflow_dispatch: schedule: - cron: "0 16 * * *" jobs: - cd: + CD: runs-on: "ubuntu-latest" steps: - - name: validate branch - if: ${{ github.ref != 'refs/heads/main' || github.ref != 'refs/heads/dev' }} + - name: Validate branch + if: ${{ github.ref != 'refs/heads/dev' }} run: | echo It's not allowed to run CD on other branch except main and dev. exit 1 - - name: checkout - uses: actions/checkout@v2 - with: - fetch-depth: 0 - token: ${{ secrets.GITHUB_TOKEN }} - ref: ${{ github.ref }} + - uses: actions/checkout@v2 - uses: actions/setup-node@v3 with: node-version: 18 - - name: semver-releaser - uses: heyvito/semver-releaser@v0.0.10 - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - - - name: build visx + - name: Build visx run: | - npm run package + npm install + npx vsce package --no-dependencies - - name: upload release info to artifact - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v3 with: name: release path: |