Skip to content

Commit 25448e0

Browse files
committed
extension/src/config.ts: handle the version with '-dev' as prerelease
And change the version string in package.json on master to v0.44.0-dev to indicate it is the dev version for v0.44.0. Prerelease versions will use v0.43.X. While doing so, I learned that the version string must have Major.Minor.Patch[-prerelease] format, and strings like "v0.44-dev" are not acceptable. Otherwise, `vsce` and vscode test framework fails to build the extension quite mysteriously. Change-Id: I6e73b2bf6d0f41b491844345193064320dd401e3 Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/615775 Commit-Queue: Hyang-Ah Hana Kim <[email protected]> Reviewed-by: Hongxiang Jiang <[email protected]> kokoro-CI: kokoro <[email protected]>
1 parent cce5f07 commit 25448e0

File tree

4 files changed

+13
-5
lines changed

4 files changed

+13
-5
lines changed

CHANGELOG.md

+5
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/).
55

66
## Unreleased
77

8+
### Code Health
9+
10+
* Extension build target is set to `es2022`. ([Issue 3540](https://github.com/golang/vscode-go/issues/3540))
11+
* The extension release workflow is migrated to the Go project's [Relui](https://pkg.go.dev/golang.org/x/build/cmd/relui#section-readme). ([Issue 3500](https://github.com/golang/vscode-go/issues/3500))
12+
813
## v0.42.1
914

1015
Date: 9 Sep, 2024

extension/package-lock.json

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

extension/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "go",
33
"displayName": "Go",
4-
"version": "0.43.0-dev",
4+
"version": "0.44.0-dev",
55
"publisher": "golang",
66
"description": "Rich Go language support for Visual Studio Code",
77
"author": {

extension/src/config.ts

+5-2
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,11 @@ export class ExtensionInfo {
4646
this.version = version?.format();
4747
this.appName = vscode.env.appName;
4848

49-
// golang.go prerelease: minor version is an odd number.
50-
this.isPreview = !!(extensionId === 'golang.go' && version && version.minor % 2 === 1);
49+
// golang.go prerelease: minor version is an odd number, or has the "-dev" suffix.
50+
this.isPreview =
51+
extensionId === 'golang.go' && !!version
52+
? version.minor % 2 === 1 || version.toString().endsWith('-dev')
53+
: false;
5154
this.isInCloudIDE =
5255
process.env.CLOUD_SHELL === 'true' ||
5356
process.env.MONOSPACE_ENV === 'true' ||

0 commit comments

Comments
 (0)