From 976a23487452c616f5d9ad37192158c8a6009e12 Mon Sep 17 00:00:00 2001 From: Francisco Hodge Date: Mon, 26 Aug 2019 22:36:24 -0400 Subject: [PATCH] Update and rename nodejs.yml to build.yml --- .github/workflows/build.yml | 39 +++++++++++++++++++++++ .github/workflows/nodejs.yml | 60 ------------------------------------ 2 files changed, 39 insertions(+), 60 deletions(-) create mode 100644 .github/workflows/build.yml delete mode 100644 .github/workflows/nodejs.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 00000000..56bf2134 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,39 @@ +name: Build + +on: + push: + branches: + - master + - staging + +jobs: + build: + runs-on: ${{ matrix.os }} + strategy: + matrix: + node-version: [12.x] + os: [ubuntu-latest] + steps: + - uses: actions/checkout@v1 + - name: Use Node.js ${{ matrix.node_version }} + uses: actions/setup-node@v1 + with: + node-version: ${{ matrix.node_version }} + - name: npm install, build, and test + run: | + npm install + npm run start -- --testMode + npm run demo + npm run coverage + - uses: codecov/codecov-action@v1.0.2 + with: + token: ${{secrets.CODECOV_TOKEN}} + env: + CI: true + - name: Discord notification + env: + DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }} + uses: Ilshidur/action-discord@master + with: + args: 'Project CI Build Complete' + diff --git a/.github/workflows/nodejs.yml b/.github/workflows/nodejs.yml deleted file mode 100644 index 0d5a1053..00000000 --- a/.github/workflows/nodejs.yml +++ /dev/null @@ -1,60 +0,0 @@ -name: Build - -on: - push: - branches: - - master - - staging - -jobs: - build: - runs-on: ${{ matrix.os }} - strategy: - matrix: - node-version: [12.x] - os: [ubuntu-latest] - steps: - - uses: actions/checkout@v1 - - name: Use Node.js ${{ matrix.node_version }} - uses: actions/setup-node@v1 - with: - node-version: ${{ matrix.node_version }} - - name: npm install, build, and test - run: | - npm install - npm run start -- --testMode - npm run demo - npm run coverage - - uses: codecov/codecov-action@v1.0.2 - with: - token: ${{secrets.CODECOV_TOKEN}} - env: - CI: true - - publish-npm: - needs: build - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v1 - - uses: actions/setup-node@v1 - with: - node-version: 12 - registry-url: https://registry.npmjs.org/ - - run: npm install && npm publish - env: - NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} - - publish-gpr: - needs: build - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v1 - - uses: actions/setup-node@v1 - with: - node-version: 12 - registry-url: https://npm.pkg.github.com/ - scope: '@hodgef' - - run: npm install && npm publish - env: - NODE_AUTH_TOKEN: ${{secrets.GH_TOKEN}} -