-
Notifications
You must be signed in to change notification settings - Fork 26
52 lines (43 loc) · 1.26 KB
/
webpack_ci.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: NodeJS with Webpack
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20.x]
steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Build and package
run: |
npm install
npx webpack
npm install -g vsce
vsce package
- name: get .vsix name
run: |
echo "vsix_name=$(echo *.vsix)" >> $GITHUB_ENV
cat $GITHUB_ENV
- name: Upload dist artifacts
uses: actions/upload-artifact@v3
with:
name: test_vsix
path: ${{env.vsix_name}}
- name: Post comment
uses: actions/github-script@v5
with:
script: |
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: '👋 A new build is available for this PR based on ${{ github.event.pull_request.head.sha }}.\n * [Download here.](https://github.com/halcyon-tech/vscode-db2i/actions/runs/${{ github.run_id }})\n'
})