forked from codefori/vscode-ibmi
-
Notifications
You must be signed in to change notification settings - Fork 0
53 lines (42 loc) · 1.83 KB
/
prerelease.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
53
on: workflow_dispatch
jobs:
publish_prerelease:
runs-on: ubuntu-latest
steps:
- name: Use Node.js 20
uses: actions/setup-node@v3
with:
node-version: 20
registry-url: 'https://registry.npmjs.org'
- uses: actions/checkout@v3
with:
ref: ${{ github.ref }}
- name: Install dependencies
run: npm ci
- name: Update version number for prelease
run: |
npm version --no-git-tag-version patch
cd types && npm version --no-git-tag-version patch
- name: get-npm-version
id: package-version
uses: martinbeentjes/[email protected]
- name: Package
run: npx @vscode/vsce package --pre-release
- name: Publish on VS Code marketplace
run: npx @vscode/vsce publish --skip-duplicate --packagePath code-for-ibmi-${{ steps.package-version.outputs.current-version}}.vsix --pat ${{ secrets.PUBLISHER_TOKEN }}
- name: Publish on Open VSX
run: npx ovsx publish --skip-duplicate --packagePath code-for-ibmi-${{ steps.package-version.outputs.current-version}}.vsix --pat ${{ secrets.OPENVSX_TOKEN }}
continue-on-error: true
- name: Bump version number for next dev cycle
run: |
npm version --no-git-tag-version prerelease --preid dev
cd types && npm version --no-git-tag-version prerelease --preid dev
- name: get-npm-version
id: devcycle-version
uses: martinbeentjes/[email protected]
- name: Commit version bump
run: |
git config user.name 'github-actions[bot]'
git config user.email 'github-actions[bot]@users.noreply.github.com'
git commit --allow-empty -a -m "Pre-release ${{ steps.devcycle-version.outputs.current-version}}"
git push