Skip to content

Instantly share code, notes, and snippets.

@cvcore
Last active April 9, 2024 13:07
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cvcore/8e187163f41a77f5271c26a870e52778 to your computer and use it in GitHub Desktop.
Save cvcore/8e187163f41a77f5271c26a870e52778 to your computer and use it in GitHub Desktop.
Manual download vscode-server
#!/bin/bash
# This script downloads and installs a specific version of VSCode Server for Linux.
# The version is specified by the first argument to the script.
# You can find the git commit id in the output of Remote - SSH plugin in VSCode.
# The output looks like this:
# ...
# Using commit id "af28b32d7e553898b2a91af498b1fb666fdebe0c" and quality "stable" for server
# ...
git_cid="$1"
echo "Installing VSCode Server version: ${git_cid}"
install_path="${HOME}/.vscode-server/bin/${git_cid}"
pushd /tmp
wget -O vscode-server.tar.gz https://update.code.visualstudio.com/commit:${git_cid}/server-linux-x64/stable
mkdir -p ${install_path}
tar -xzf vscode-server.tar.gz -C ${install_path} --strip-components 1
touch ${install_path}/0
popd
@cvcore
Copy link
Author

cvcore commented Dec 14, 2023

This script will manually download the vscode-server when it fails to be installed automatically.

To use this script, simply copy and paste

/bin/bash -c "$(curl -fsSL https://gist.githubusercontent.com/cvcore/8e187163f41a77f5271c26a870e52778/raw/download_vscode_server.sh)" -- commit_id

Into your command line. You need to replace the commit_id with your specific version found in the Remote - SSH plugin output.

Try to look for something like this:

Using commit id "af28b32d7e553898b2a91af498b1fb666fdebe0c" and quality "stable" for server

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment