From a7793257c990f22e965f88e02929c81f828d7a78 Mon Sep 17 00:00:00 2001 From: Brandon Phillips Date: Tue, 28 Jan 2020 16:55:21 -0700 Subject: [PATCH] fix(ci): migrate workflows to yaml syntax --- .github/main.workflow | 28 ---------------------------- .github/workflows/push.yml | 23 +++++++++++++++++++++++ 2 files changed, 23 insertions(+), 28 deletions(-) delete mode 100644 .github/main.workflow create mode 100644 .github/workflows/push.yml diff --git a/.github/main.workflow b/.github/main.workflow deleted file mode 100644 index b006e21..0000000 --- a/.github/main.workflow +++ /dev/null @@ -1,28 +0,0 @@ -workflow "Test and Release" { - on = "push" - resolves = ["Test", "Release"] -} - -action "Install" { - uses = "nuxt/actions-yarn@97f98f200b7fd42a001f88e7bdfc14d64d695ab2" - args = "install" -} - -action "Test" { - needs = "Install" - uses = "nuxt/actions-yarn@97f98f200b7fd42a001f88e7bdfc14d64d695ab2" - args = "test" -} - -action "Master" { - needs = "Test" - uses = "actions/bin/filter@master" - args = "branch master" -} - -action "Release" { - needs = "Master" - uses = "nuxt/actions-yarn@97f98f200b7fd42a001f88e7bdfc14d64d695ab2" - secrets = ["GH_TOKEN", "NPM_TOKEN"] - args = "release-ci" -} diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml new file mode 100644 index 0000000..5523210 --- /dev/null +++ b/.github/workflows/push.yml @@ -0,0 +1,23 @@ +name: CI/CD +on: push + +jobs: + test-and-release: + name: Test and Release + runs-on: ubuntu-latest + steps: + # Checkout the repo at the push ref + - uses: actions/checkout@v1 + # Install deps + - name: Install + run: yarn + # Run tests + - name: Test + run: yarn test + # Attempt release if we're on master + - name: Release + if: github.ref == 'refs/heads/master' + run: yarn run release-ci + env: + GH_TOKEN: ${{ secrets.GH_TOKEN }} + NPM_TOKEN: ${{ secrets.NPM_TOKEN }}