From 62e88f328750e0ca9857c9fd9c61b9256b5637c0 Mon Sep 17 00:00:00 2001 From: Vinayak Kulkarni Date: Sun, 26 Jul 2020 19:17:31 +0530 Subject: [PATCH] fix(ci): update ship.js trigger to trigger on `main` branch --- .github/workflows/shipjs-trigger.yml | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/.github/workflows/shipjs-trigger.yml b/.github/workflows/shipjs-trigger.yml index d6e433bc..1c01bcc4 100644 --- a/.github/workflows/shipjs-trigger.yml +++ b/.github/workflows/shipjs-trigger.yml @@ -2,25 +2,28 @@ name: Ship js trigger on: push: branches: - - master + - main jobs: build: name: Release runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - name: Checkout latest code + uses: actions/checkout@v2 with: - ref: master - - uses: actions/setup-node@v1 + fetch-depth: 0 + ref: main + + - name: Setup node environment + uses: actions/setup-node@v1 with: registry-url: "https://registry.npmjs.org" - - run: | - if [ -f "yarn.lock" ]; then - yarn install - else - npm install - fi - - run: npx shipjs trigger + + - name: Install required dependencies + run: npm install + + - name: Run ship.js trigger to build new version + run: npx shipjs trigger env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}