Skip to content

Commit

Permalink
all: remove reference to the nightly extension
Browse files Browse the repository at this point in the history
The nightly is deprecated in favor of the new pre-release versions.
Clean up docs and references.

Use "Pre-release" instead of "Preview" in user-facing doc.
(We also use "insiders" or "preview" to refer to VS Code Pre-release
inside our code or project to distinguish from semver's prerelease,
but outside our project, "Pre-release extension" is the term to use)

For #1953

Change-Id: Id9e5cc53fb1f459e69e7aa264ef76799b069c676
Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/613178
kokoro-CI: kokoro <[email protected]>
Reviewed-by: Robert Findley <[email protected]>
Commit-Queue: Hyang-Ah Hana Kim <[email protected]>
  • Loading branch information
hyangah committed Sep 18, 2024
1 parent 1c7cd8f commit c233889
Show file tree
Hide file tree
Showing 11 changed files with 21 additions and 198 deletions.
14 changes: 11 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,11 +125,19 @@ modules or uncommon project layouts, you will need to configure your workspace
by using [Workspace Folders]. See the
[Supported workspace layouts documentation] for more information.

## Preview version
## Pre-release version

If you'd like to get early access to new features and bug fixes, you can use the
nightly build of this extension. Learn how to install it in by reading the
[Go Nightly documentation](https://github.com/golang/vscode-go/wiki/nightly).
pre-release extension. Following the vscode's [convention](https://code.visualstudio.com/api/working-with-extensions/publishing-extension#prerelease-extensions),
we use the minor version of the extension version number to distinguish stable
and pre-release versions (`0.ODD_NUMBER.patch` for pre-release, `0.EVEN_NUMBER.patch`
for stable release).

To install the pre-release version, use the drop-down list
to select "Install Pre-Release Version", or if already installed the Go extension,
use the "Switch to Pre-Release Version" option in the Visual Studio Code
extension management page. For more details about this mechanism, see the
[Visual Studio Code's documentation](https://code.visualstudio.com/updates/v1_63#_pre-release-extensions).

## Telemetry

Expand Down
6 changes: 3 additions & 3 deletions build/README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
### Release process

The golang.go-nightly extension is released daily during weekdays, based on the latest commit to the master branch.
> 🚧 Under construction 🚧
(Note: the release process is currently in GH workflow. We are in process of moving it to a GCB workflow.)
We are currently working on migrating the release process to the Go project's relui (golang.org/x/build/cmd/relui).

* Dockerfile: defines the image containing tools and environments needed to build and test the extension. (e.g. Go, Node.js, jq, etc.)
* build-ci-image.yaml: defines the workflow to build the container image used for extension testing and releasing.
* release-nightly.yaml: defines the workflow that builds the nightly extension and runs tests. The built extension is pushed only after all tests pass.
* release.yaml: defines the (soon-to-be-deprecated) workflow to build/publish the extension in GCB.
37 changes: 2 additions & 35 deletions build/all.bash
Original file line number Diff line number Diff line change
Expand Up @@ -77,32 +77,6 @@ run_test_in_docker() {
docker run --cap-add SYS_PTRACE --shm-size=8G --workdir=/workspace -v "$(pwd):/workspace" vscode-test-env ci
}

prepare_nightly() {
# Version format: YYYY.MM.DDHH based on the latest commit timestamp.
# e.g. 2020.1.510 is the version built based on a commit that was made
# on 2020/01/05 10:00
local VER=`git log -1 --format=%cd --date="format:%Y.%-m.%-d%H"`
local COMMIT=`git log -1 --format=%H`
echo "**** Preparing nightly release : ${VER} (${COMMIT}) ***"
# Update package.json
(cat extension/package.json | jq --arg VER "${VER}" '
.version=$VER |
.preview=true |
.name="go-nightly" |
.displayName="Go Nightly" |
.publisher="golang" |
.description="Rich Go language support for Visual Studio Code (Nightly)" |
.contributes.configuration.properties."go.delveConfig".properties.hideSystemGoroutines.default=true
') > /tmp/package.json && cp /tmp/package.json extension/package.json

# Replace CHANGELOG.md with CHANGELOG.md + Release commit info.
printf "**Release ${VER} @ ${COMMIT}** \n\n" | cat - extension/CHANGELOG.md > /tmp/CHANGELOG.md.new && mv /tmp/CHANGELOG.md.new extension/CHANGELOG.md
# Replace the heading of README.md with the heading for Go Nightly.
sed '/^# Go for Visual Studio Code$/d' README.md | cat build/nightly/README.md - > /tmp/README.md.new && mv /tmp/README.md.new README.md
# Replace src/const.ts with build/nightly/const.ts.
cp build/nightly/const.ts extension/src/const.ts
}

main() {
cd "$(root_dir)" # always start to run from the extension source root.
case "$1" in
Expand All @@ -120,17 +94,10 @@ main() {
"ci")
go_binaries_info
setup_virtual_display
run_doc_test
run_doc_test
run_test
run_lint
;;
"prepare_nightly")
prepare_nightly
run_lint
;;
"test_nightly")
setup_virtual_display
run_test
;;
*)
usage
exit 2
Expand Down
14 changes: 0 additions & 14 deletions build/nightly/README.md

This file was deleted.

9 changes: 0 additions & 9 deletions build/nightly/const.ts

This file was deleted.

84 changes: 0 additions & 84 deletions build/release-nightly.yaml

This file was deleted.

2 changes: 1 addition & 1 deletion docs/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

We welcome your contributions and thank you for working to improve the Go development experience in VS Code.

This guide will explain the process of setting up your development environment to work on the VS Code Go extension, as well as the process of sending out your change for review. If you're interested in testing the master branch or pre-releases of the extension, please see the [Go Nightly documentation](nightly.md).
This guide will explain the process of setting up your development environment to work on the VS Code Go extension, as well as the process of sending out your change for review.

Our canonical Git repository is located at https://go.googlesource.com/vscode-go and https://github.com/golang/vscode-go is a mirror.

Expand Down
2 changes: 1 addition & 1 deletion docs/debugging.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ adapter in favor of direct communication with Delve via
📣 **We are happy to announce that the new _`dlv-dap`_ mode of Delve
integration is enabled for _local_ _debugging_ by default. For
[_remote_ _debugging_](#remote-debugging) it is the default in
[Go Nightly](nightly.md) and is available with stable builds on demand with
[pre-release versions](https://github.com/golang/vscode-go/blob/master/README.md#pre-release-version) and is available with stable builds on demand with
`"debugAdapter": "dlv-dap"` attribute in `launch.json` or `settings.json`!**

Many features and settings described in this document may be available only with
Expand Down
43 changes: 0 additions & 43 deletions docs/nightly.md

This file was deleted.

4 changes: 1 addition & 3 deletions extension/src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,8 @@ export class ExtensionInfo {
this.version = version?.format();
this.appName = vscode.env.appName;

// golang.go-nightly: packageJSON.preview is true.
// golang.go prerelease: minor version is an odd number.
this.isPreview =
!!packageJSON?.preview || !!(extensionId === 'golang.go' && version && version.minor % 2 === 1);
this.isPreview = !!(extensionId === 'golang.go' && version && version.minor % 2 === 1);
this.isInCloudIDE =
process.env.CLOUD_SHELL === 'true' ||
process.env.MONOSPACE_ENV === 'true' ||
Expand Down
4 changes: 2 additions & 2 deletions extension/src/goInstallTools.ts
Original file line number Diff line number Diff line change
Expand Up @@ -902,8 +902,8 @@ export async function maybeInstallVSCGO(
extensionPath: string,
isPreview: boolean
): Promise<string> {
// golang.go stable, golang.go-nightly stable -> install once per version.
// golang.go dev through launch.json -> install every time.
// golang.go stable stable -> install once per version.
// golang.go pre-release/dev through launch.json -> install every time.
const progPath = path.join(extensionPath, 'bin', correctBinname('vscgo'));

if (extensionMode === vscode.ExtensionMode.Production && executableFileExists(progPath)) {
Expand Down

0 comments on commit c233889

Please sign in to comment.