Skip to content

Commit 6493d36

Browse files
committed
ci: move release to a separate job
1 parent 6e84529 commit 6493d36

File tree

1 file changed

+16
-2
lines changed

1 file changed

+16
-2
lines changed

.github/workflows/build.yml

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
run: npm run prettier
3333
- name: Lint
3434
run: npm run tslint
35-
- name: Build extension
35+
- name: Build VS Code extension
3636
run: npm run build
3737
- name: Setup PHP
3838
uses: shivammathur/setup-php@v2
@@ -50,8 +50,22 @@ jobs:
5050
- name: Upload coverage to Codecov
5151
run: bash <(curl -s https://codecov.io/bash)
5252
shell: bash
53+
release:
54+
runs-on: ubuntu-18.04
55+
needs: test
56+
if: github.repository_owner == 'felixfbecker' && github.event_name == 'push' && github.ref == 'refs/heads/master'
57+
steps:
58+
- name: Setup Node.js
59+
uses: actions/setup-node@v1
60+
with:
61+
node-version: '6.17.1'
62+
- name: Install npm
63+
run: npm install -g npm@^6.3.0
64+
- name: Install npm dependencies
65+
run: npm ci
66+
- name: Build VS Code extension
67+
run: npm run build
5368
- name: Release
54-
if: github.event_name == 'push' && github.ref == 'refs/heads/release'
5569
env:
5670
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5771
VSCE_TOKEN: ${{ secrets.VSCE_TOKEN }}

0 commit comments

Comments
 (0)