Skip to content

Commit 0ddb97d

Browse files
committed
Use custom version
1 parent bb3d0fa commit 0ddb97d

2 files changed

Lines changed: 13 additions & 3 deletions

File tree

.github/workflows/ci.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,16 @@ jobs:
3131
COMMIT_SHA: ${{ github.event.pull_request.head.sha || github.sha }}
3232
run: echo "sha_short=${COMMIT_SHA:0:7}" >> $GITHUB_OUTPUT
3333

34+
- name: Patch version with commit SHA
35+
run: |
36+
BASE_VERSION=$(jq -r .version package.json)
37+
MAJOR=$(echo "$BASE_VERSION" | cut -d. -f1)
38+
MINOR=$(echo "$BASE_VERSION" | cut -d. -f2)
39+
PATCH=${{ github.run_number }}
40+
NEW_VERSION="${MAJOR}.${MINOR}.${PATCH}"
41+
jq --arg v "$NEW_VERSION" '.version = $v' package.json > package.tmp && mv package.tmp package.json
42+
echo "Version set to $NEW_VERSION (sha: ${{ steps.vars.outputs.sha_short }})"
43+
3444
- name: Package Extension
3545
run: bunx vsce package --no-yarn -o rescript-vscode-${{ steps.vars.outputs.sha_short }}.vsix
3646

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
{
22
"name": "rescript-vscode",
33
"displayName": "ReScript",
4-
"description": "ReScript language support (official)",
4+
"description": "ReScript language support (nojaf)",
55
"author": "ReScript Team",
66
"license": "MIT",
7-
"version": "1.72.0",
7+
"version": "1.80.0",
88
"repository": {
99
"type": "git",
10-
"url": "https://github.com/rescript-lang/rescript-vscode"
10+
"url": "https://github.com/nojaf/rescript-vscode"
1111
},
1212
"publisher": "chenglou92",
1313
"icon": "logo.png",

0 commit comments

Comments
 (0)