mirror of https://github.com/coder/code-server.git
commit
d986d85f87
|
@ -2,7 +2,7 @@ parser: "@typescript-eslint/parser"
|
|||
env:
|
||||
browser: true
|
||||
es6: true # Map, etc.
|
||||
mocha: true
|
||||
jest: true
|
||||
node: true
|
||||
|
||||
parserOptions:
|
||||
|
@ -15,8 +15,12 @@ extends:
|
|||
- plugin:import/recommended
|
||||
- plugin:import/typescript
|
||||
- plugin:prettier/recommended
|
||||
- prettier # Removes eslint rules that conflict with prettier.
|
||||
- prettier/@typescript-eslint # Remove conflicts again.
|
||||
# Recommended by jest-playwright
|
||||
# https://github.com/playwright-community/jest-playwright#globals
|
||||
- plugin:jest-playwright/recommended
|
||||
# Prettier should always be last
|
||||
# Removes eslint rules that conflict with prettier.
|
||||
- prettier
|
||||
|
||||
rules:
|
||||
# Sometimes you need to add args to implement a function signature even
|
||||
|
@ -30,6 +34,7 @@ rules:
|
|||
"@typescript-eslint/no-var-requires": off
|
||||
"@typescript-eslint/explicit-module-boundary-types": off
|
||||
"@typescript-eslint/no-explicit-any": off
|
||||
"@typescript-eslint/no-extra-semi": off
|
||||
eqeqeq: error
|
||||
import/order:
|
||||
[error, { alphabetize: { order: "asc" }, groups: [["builtin", "external", "internal"], "parent", "sibling"] }]
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
*.afdesign filter=lfs diff=lfs merge=lfs -text
|
|
@ -1 +1,3 @@
|
|||
* @cdr/code-server-reviewers
|
||||
|
||||
ci/helm-chart @Matthew-Beckett @alexgorbatchev
|
||||
|
|
|
@ -7,22 +7,43 @@ assignees: ""
|
|||
---
|
||||
|
||||
<!--
|
||||
Please see https://github.com/cdr/code-server/blob/master/doc/FAQ.md#how-do-i-debug-issues-with-code-server
|
||||
and include any logging information relevant to the issue.
|
||||
|
||||
Please search for existing issues before filing.
|
||||
Hi there! 👋
|
||||
|
||||
If you can reproduce the issue on vanilla VS Code,
|
||||
please file the issue at the VS Code repository instead.
|
||||
Thanks for reporting a bug. Please see https://github.com/cdr/code-server/blob/main/docs/FAQ.md#how-do-i-debug-issues-with-code-server and include any logging information relevant to the issue.
|
||||
|
||||
Provide screenshots if applicable.
|
||||
|
||||
Please fill in the issue template and try to be as detailed
|
||||
and clear as possible!
|
||||
Please search for existing issues before filing, as they may contain additional information about the problem and descriptions of workarounds. Provide as much information as you can, so that we can reproduce the issue. Otherwise, we may not be able to help diagnose the problem, and may close the issue as unreproducible or incomplete. For visual defects, please include screenshots to help us understand the issue.
|
||||
-->
|
||||
|
||||
## OS/Web Information
|
||||
|
||||
- Web Browser:
|
||||
- Local OS:
|
||||
- Remote OS:
|
||||
- Remote Architecture:
|
||||
- `code-server --version`:
|
||||
|
||||
## Steps to Reproduce
|
||||
|
||||
1.
|
||||
2.
|
||||
3.
|
||||
|
||||
## Expected
|
||||
|
||||
<!-- What should happen? -->
|
||||
|
||||
## Actual
|
||||
|
||||
<!-- What actually happens? -->
|
||||
|
||||
## Screenshot
|
||||
|
||||
<!-- Ideally provide a screenshot, gif, video or screenrecording -->
|
||||
|
||||
## Notes
|
||||
|
||||
<!-- If you can reproduce the issue on vanilla VS Code,
|
||||
please file the issue at the VS Code repository instead. -->
|
||||
|
||||
This issue can be reproduced in VS Code: Yes/No
|
||||
|
|
|
@ -9,7 +9,7 @@ assignees: ""
|
|||
<!--
|
||||
Details on the code-server extension marketplace are at
|
||||
|
||||
https://github.com/cdr/code-server/blob/master/doc/FAQ.md#whats-the-deal-with-extensions
|
||||
https://github.com/cdr/code-server/blob/master/docs/FAQ.md#whats-the-deal-with-extensions
|
||||
|
||||
Please fill in the issue template!
|
||||
-->
|
||||
|
|
|
@ -0,0 +1,18 @@
|
|||
<!-- Note: this variable $CODE_SERVER_VERSION_TO_UPDATE will be set when you run the release-prep.sh script with `yarn release:prep` -->
|
||||
|
||||
This PR is to generate a new release of `code-server` at `$CODE_SERVER_VERSION_TO_UPDATE`
|
||||
|
||||
## Screenshot
|
||||
|
||||
TODO
|
||||
|
||||
## TODOs
|
||||
|
||||
- [ ] test locally
|
||||
- [ ] upload assets to draft release
|
||||
- [ ] test one of the release packages locally
|
||||
- [ ] double-check github release tag is the commit with artifacts (_note gets messed up after uploading assets_)
|
||||
- [ ] publish release
|
||||
- [ ] merge PR
|
||||
- [ ] update the homebrew package
|
||||
- [ ] update the AUR package
|
|
@ -0,0 +1,26 @@
|
|||
version: 2
|
||||
updates:
|
||||
- package-ecosystem: "github-actions"
|
||||
directory: "/"
|
||||
schedule:
|
||||
interval: "daily"
|
||||
time: "11:00"
|
||||
ignore:
|
||||
# GitHub always delivers the latest versions for each major
|
||||
# release tag, so handle updates manually
|
||||
- dependency-name: "actions/*"
|
||||
|
||||
- package-ecosystem: "npm"
|
||||
directory: "/"
|
||||
schedule:
|
||||
interval: "daily"
|
||||
time: "11:00"
|
||||
ignore:
|
||||
- dependency-name: "@types/node"
|
||||
versions: ["14.x", "13.x"]
|
||||
- dependency-name: "xdg-basedir"
|
||||
# 5.0.0 has breaking changes as they switch to named exports
|
||||
# and convert the module to ESM
|
||||
# We can't use it until we switch to ESM across the project
|
||||
# See release notes: https://github.com/sindresorhus/xdg-basedir/releases/tag/v5.0.0
|
||||
versions: ["5.x"]
|
|
@ -0,0 +1,45 @@
|
|||
# Configuration for the repo ranger bot
|
||||
# See docs: https://www.notion.so/Documentation-8d7627bb1f3c42b7b1820e8d6f157a57#9879d1374fab4d1f9c607c230fd5123d
|
||||
default:
|
||||
close:
|
||||
# Default time to wait before closing the label. Can either be a number in milliseconds
|
||||
# or a string specified by the `ms` package (https://www.npmjs.com/package/ms)
|
||||
delay: "2 days"
|
||||
|
||||
# Default comment to post when an issue is first marked with a closing label
|
||||
comment: "⚠️ This issue has been marked $LABEL and will be closed in $DELAY."
|
||||
|
||||
labels:
|
||||
duplicate: close
|
||||
wontfix: close
|
||||
"squash when passing": merge
|
||||
"rebase when passing": merge
|
||||
"merge when passing": merge
|
||||
stale:
|
||||
action: close
|
||||
delay: 7 days
|
||||
comment: "⚠️ This issue has been marked stale and will automatically be closed in $DELAY."
|
||||
"new contributor":
|
||||
action: comment
|
||||
delay: 5s
|
||||
message: "Thanks for making your first contribution! :slightly_smiling_face:"
|
||||
extension-request:
|
||||
action: close
|
||||
delay: 5s
|
||||
message: >
|
||||
Thanks for opening an extension request!
|
||||
We are currently in the process of switching extension
|
||||
marketplaces and transitioning over to [Open VSX](https://open-vsx.org/).
|
||||
Once https://github.com/eclipse/openvsx/issues/249 is implemented, we
|
||||
can fully make this transition. Therefore, we are no longer accepting
|
||||
new requests for extension requests. We suggest installing the VSIX
|
||||
file and then installing into code-server as a temporary workaround.
|
||||
See [docs](https://github.com/cdr/code-server/blob/main/docs/FAQ.md#installing-vsix-extensions-via-the-command-line) for more info.
|
||||
"upstream:vscode":
|
||||
action: close
|
||||
delay: 5s
|
||||
comment: >
|
||||
This issue has been marked as 'upstream:vscode'.
|
||||
Please file this upstream: [link to open issue](https://github.com/microsoft/vscode/issues/new/choose)
|
||||
|
||||
This issue will automatically close in $DELAY.
|
|
@ -1,144 +1,400 @@
|
|||
name: ci
|
||||
|
||||
on: [push]
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
|
||||
# Note: if: success() is used in several jobs -
|
||||
# this ensures that it only executes if all previous jobs succeeded.
|
||||
|
||||
# if: steps.cache-yarn.outputs.cache-hit != 'true'
|
||||
# will skip running `yarn install` if it successfully fetched from cache
|
||||
|
||||
jobs:
|
||||
fmt:
|
||||
prebuild:
|
||||
name: Pre-build checks
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: Run ./ci/steps/fmt.sh
|
||||
uses: ./ci/images/debian10
|
||||
with:
|
||||
args: ./ci/steps/fmt.sh
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v2
|
||||
|
||||
lint:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: Run ./ci/steps/lint.sh
|
||||
uses: ./ci/images/debian10
|
||||
- name: Install Node.js v12
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
args: ./ci/steps/lint.sh
|
||||
node-version: "12"
|
||||
|
||||
test:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: Run ./ci/steps/test.sh
|
||||
uses: ./ci/images/debian10
|
||||
with:
|
||||
args: ./ci/steps/test.sh
|
||||
- name: Install helm
|
||||
uses: azure/setup-helm@v1.1
|
||||
|
||||
release:
|
||||
- name: Fetch dependencies from cache
|
||||
id: cache-yarn
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: "**/node_modules"
|
||||
key: yarn-build-${{ hashFiles('**/yarn.lock') }}
|
||||
|
||||
- name: Install dependencies
|
||||
if: steps.cache-yarn.outputs.cache-hit != 'true'
|
||||
run: yarn --frozen-lockfile
|
||||
|
||||
- name: Audit for vulnerabilities
|
||||
run: yarn _audit
|
||||
if: success()
|
||||
|
||||
- name: Run yarn fmt
|
||||
run: yarn fmt
|
||||
if: success()
|
||||
|
||||
- name: Run yarn lint
|
||||
run: yarn lint
|
||||
if: success()
|
||||
|
||||
- name: Run code-server unit tests
|
||||
run: yarn test:unit
|
||||
if: success()
|
||||
|
||||
build:
|
||||
name: Build
|
||||
needs: prebuild
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: Run ./ci/steps/release.sh
|
||||
uses: ./ci/images/debian10
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
args: ./ci/steps/release.sh
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Install Node.js v12
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: "12"
|
||||
|
||||
- name: Fetch dependencies from cache
|
||||
id: cache-yarn
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: "**/node_modules"
|
||||
key: yarn-build-${{ hashFiles('**/yarn.lock') }}
|
||||
|
||||
- name: Install dependencies
|
||||
if: steps.cache-yarn.outputs.cache-hit != 'true'
|
||||
run: yarn --frozen-lockfile
|
||||
|
||||
- name: Build code-server
|
||||
run: yarn build
|
||||
|
||||
# Parse the hash of the latest commit inside lib/vscode
|
||||
# use this to avoid rebuilding it if nothing changed
|
||||
# How it works: the `git log` command fetches the hash of the last commit
|
||||
# that changed a file inside `lib/vscode`. If a commit changes any file in there,
|
||||
# the hash returned will change, and we rebuild vscode. If the hash did not change,
|
||||
# (for example, a change to `src/` or `docs/`), we reuse the same build as last time.
|
||||
# This saves a lot of time in CI, as compiling VSCode can take anywhere from 5-10 minutes.
|
||||
- name: Get latest lib/vscode rev
|
||||
id: vscode-rev
|
||||
run: echo "::set-output name=rev::$(git log -1 --format='%H' ./lib/vscode)"
|
||||
|
||||
- name: Attempt to fetch vscode build from cache
|
||||
id: cache-vscode
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: |
|
||||
lib/vscode/.build
|
||||
lib/vscode/out-build
|
||||
lib/vscode/out-vscode
|
||||
lib/vscode/out-vscode-min
|
||||
key: vscode-build-${{ steps.vscode-rev.outputs.rev }}
|
||||
|
||||
- name: Build vscode
|
||||
if: steps.cache-vscode.outputs.cache-hit != 'true'
|
||||
run: yarn build:vscode
|
||||
|
||||
# The release package does not contain any native modules
|
||||
# and is neutral to architecture/os/libc version.
|
||||
- name: Create release package
|
||||
run: yarn release
|
||||
if: success()
|
||||
|
||||
# https://github.com/actions/upload-artifact/issues/38
|
||||
- name: Compress release package
|
||||
run: tar -czf package.tar.gz release
|
||||
|
||||
- name: Upload npm package artifact
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: npm-package
|
||||
path: ./release-npm-package
|
||||
path: ./package.tar.gz
|
||||
|
||||
linux-amd64:
|
||||
needs: release
|
||||
# TODO: cache building yarn --production
|
||||
# possibly 2m30s of savings(?)
|
||||
# this requires refactoring our release scripts
|
||||
package-linux-amd64:
|
||||
name: x86-64 Linux build
|
||||
needs: build
|
||||
runs-on: ubuntu-latest
|
||||
container: "centos:7"
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Install Node.js v12
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: "12"
|
||||
|
||||
- name: Install development tools
|
||||
run: |
|
||||
yum install -y epel-release centos-release-scl
|
||||
yum install -y devtoolset-9-{make,gcc,gcc-c++} jq rsync
|
||||
|
||||
- name: Install nfpm and envsubst
|
||||
run: |
|
||||
curl -sfL https://install.goreleaser.com/github.com/goreleaser/nfpm.sh | sh -s -- -b ~/.local/bin v2.3.1
|
||||
curl -L https://github.com/a8m/envsubst/releases/download/v1.1.0/envsubst-`uname -s`-`uname -m` -o envsubst
|
||||
chmod +x envsubst
|
||||
mv envsubst ~/.local/bin
|
||||
echo "$HOME/.local/bin" >> $GITHUB_PATH
|
||||
|
||||
- name: Install yarn
|
||||
run: npm install -g yarn
|
||||
|
||||
- name: Download npm package
|
||||
uses: actions/download-artifact@v2
|
||||
with:
|
||||
name: npm-package
|
||||
path: ./release-npm-package
|
||||
- name: Run ./ci/steps/release-packages.sh
|
||||
uses: ./ci/images/centos7
|
||||
with:
|
||||
args: ./ci/steps/release-packages.sh
|
||||
|
||||
- name: Decompress npm package
|
||||
run: tar -xzf package.tar.gz
|
||||
|
||||
# NOTE: && here is deliberate - GitHub puts each line in its own `.sh`
|
||||
# file when running inside a docker container.
|
||||
- name: Build standalone release
|
||||
run: source scl_source enable devtoolset-9 && yarn release:standalone
|
||||
|
||||
- name: Sanity test standalone release
|
||||
run: yarn test:standalone-release
|
||||
|
||||
- name: Build packages with nfpm
|
||||
run: yarn package
|
||||
|
||||
- name: Upload release artifacts
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: release-packages
|
||||
path: ./release-packages
|
||||
|
||||
linux-arm64:
|
||||
needs: release
|
||||
runs-on: ubuntu-arm64-latest
|
||||
# NOTE@oxy:
|
||||
# We use Ubuntu 16.04 here, so that our build is more compatible
|
||||
# with older libc versions. We used to (Q1'20) use CentOS 7 here,
|
||||
# but it has a full update EOL of Q4'20 and a 'critical security'
|
||||
# update EOL of 2024. We're dropping full support a few years before
|
||||
# the final EOL, but I don't believe CentOS 7 has a large arm64 userbase.
|
||||
# It is not feasible to cross-compile with CentOS.
|
||||
|
||||
# Cross-compile notes: To compile native dependencies for arm64,
|
||||
# we install the aarch64 cross toolchain and then set it as the default
|
||||
# compiler/linker/etc. with the AR/CC/CXX/LINK environment variables.
|
||||
# qemu-user-static on ubuntu-16.04 currently doesn't run Node correctly,
|
||||
# so we just build with "native"/x86_64 node, then download arm64 node
|
||||
# and then put it in our release. We can't smoke test the arm64 build this way,
|
||||
# but this means we don't need to maintain a self-hosted runner!
|
||||
package-linux-arm64:
|
||||
name: Linux ARM64 cross-compile build
|
||||
needs: build
|
||||
runs-on: ubuntu-16.04
|
||||
env:
|
||||
AR: aarch64-linux-gnu-ar
|
||||
CC: aarch64-linux-gnu-gcc
|
||||
CXX: aarch64-linux-gnu-g++
|
||||
LINK: aarch64-linux-gnu-g++
|
||||
NPM_CONFIG_ARCH: arm64
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Install Node.js v12
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: "12"
|
||||
|
||||
- name: Install nfpm
|
||||
run: |
|
||||
curl -sfL https://install.goreleaser.com/github.com/goreleaser/nfpm.sh | sh -s -- -b ~/.local/bin v2.3.1
|
||||
echo "$HOME/.local/bin" >> $GITHUB_PATH
|
||||
|
||||
- name: Install cross-compiler
|
||||
run: sudo apt install g++-aarch64-linux-gnu
|
||||
|
||||
- name: Download npm package
|
||||
uses: actions/download-artifact@v2
|
||||
with:
|
||||
name: npm-package
|
||||
path: ./release-npm-package
|
||||
- name: Run ./ci/steps/release-packages.sh
|
||||
uses: ./ci/images/centos7
|
||||
with:
|
||||
args: ./ci/steps/release-packages.sh
|
||||
|
||||
- name: Decompress npm package
|
||||
run: tar -xzf package.tar.gz
|
||||
|
||||
- name: Build standalone release
|
||||
run: yarn release:standalone
|
||||
|
||||
- name: Replace node with arm64 equivalent
|
||||
run: |
|
||||
wget https://nodejs.org/dist/v12.18.4/node-v12.18.4-linux-arm64.tar.gz
|
||||
tar -xzf node-v12.18.4-linux-arm64.tar.gz node-v12.18.4-linux-arm64/bin/node --strip-components=2
|
||||
mv ./node ./release-standalone/lib/node
|
||||
|
||||
- name: Build packages with nfpm
|
||||
run: yarn package arm64
|
||||
|
||||
- name: Upload release artifacts
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: release-packages
|
||||
path: ./release-packages
|
||||
|
||||
macos-amd64:
|
||||
needs: release
|
||||
package-macos-amd64:
|
||||
name: x86-64 macOS build
|
||||
needs: build
|
||||
runs-on: macos-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Install Node.js v12
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: "12"
|
||||
|
||||
- name: Install nfpm
|
||||
run: |
|
||||
curl -sfL https://install.goreleaser.com/github.com/goreleaser/nfpm.sh | sh -s -- -b ~/.local/bin v2.3.1
|
||||
echo "$HOME/.local/bin" >> $GITHUB_PATH
|
||||
|
||||
- name: Download npm package
|
||||
uses: actions/download-artifact@v2
|
||||
with:
|
||||
name: npm-package
|
||||
path: ./release-npm-package
|
||||
- run: ./ci/steps/release-packages.sh
|
||||
env:
|
||||
# Otherwise we get rate limited when fetching the ripgrep binary.
|
||||
# For whatever reason only MacOS needs it.
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Decompress npm package
|
||||
run: tar -xzf package.tar.gz
|
||||
|
||||
- name: Build standalone release
|
||||
run: yarn release:standalone
|
||||
|
||||
- name: Sanity test standalone release
|
||||
run: yarn test:standalone-release
|
||||
|
||||
- name: Build packages with nfpm
|
||||
run: yarn package
|
||||
|
||||
- name: Upload release artifacts
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: release-packages
|
||||
path: ./release-packages
|
||||
|
||||
test-e2e:
|
||||
name: End-to-end tests
|
||||
needs: package-linux-amd64
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
PASSWORD: e45432jklfdsab
|
||||
CODE_SERVER_ADDRESS: http://localhost:8080
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Install Node.js v12
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: "12"
|
||||
|
||||
- name: Install playwright
|
||||
uses: microsoft/playwright-github-action@v1
|
||||
|
||||
- name: Fetch dependencies from cache
|
||||
id: cache-yarn
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: "**/node_modules"
|
||||
key: yarn-build-${{ hashFiles('**/yarn.lock') }}
|
||||
|
||||
- name: Download release packages
|
||||
uses: actions/download-artifact@v2
|
||||
with:
|
||||
name: release-packages
|
||||
path: ./release-packages
|
||||
|
||||
- name: Untar code-server file
|
||||
run: |
|
||||
cd release-packages && tar -xzf code-server*-linux-amd64.tar.gz
|
||||
|
||||
- name: Install dependencies
|
||||
if: steps.cache-yarn.outputs.cache-hit != 'true'
|
||||
run: yarn --frozen-lockfile
|
||||
|
||||
# HACK: this shouldn't need to exist, but put it here anyway
|
||||
# in an attempt to solve Playwright cache failures.
|
||||
- name: Reinstall playwright
|
||||
if: steps.cache-yarn.outputs.cache-hit == 'true'
|
||||
run: |
|
||||
cd test/
|
||||
rm -r node_modules/playwright
|
||||
yarn install --check-files
|
||||
|
||||
- name: Run end-to-end tests
|
||||
run: |
|
||||
./release-packages/code-server*-linux-amd64/bin/code-server --log trace &
|
||||
yarn test:e2e
|
||||
|
||||
- name: Upload test artifacts
|
||||
if: always()
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: test-videos
|
||||
path: ./test/e2e/videos
|
||||
|
||||
- name: Remove release packages and test artifacts
|
||||
run: rm -rf ./release-packages ./test/e2e/videos
|
||||
|
||||
docker-amd64:
|
||||
runs-on: ubuntu-latest
|
||||
needs: linux-amd64
|
||||
needs: package-linux-amd64
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Download release package
|
||||
uses: actions/download-artifact@v2
|
||||
with:
|
||||
name: release-packages
|
||||
path: ./release-packages
|
||||
|
||||
- name: Run ./ci/steps/build-docker-image.sh
|
||||
uses: ./ci/images/debian10
|
||||
with:
|
||||
args: ./ci/steps/build-docker-image.sh
|
||||
run: ./ci/steps/build-docker-image.sh
|
||||
|
||||
- name: Upload release image
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: release-images
|
||||
path: ./release-images
|
||||
|
||||
# TODO: this is the last place where we use our self-hosted arm64 runner.
|
||||
# In the future, consider switching to docker buildx + qemu,
|
||||
# thus removing the requirement for us to maintain the runner.
|
||||
docker-arm64:
|
||||
runs-on: ubuntu-arm64-latest
|
||||
needs: linux-arm64
|
||||
needs: package-linux-arm64
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Download release package
|
||||
uses: actions/download-artifact@v2
|
||||
with:
|
||||
name: release-packages
|
||||
path: ./release-packages
|
||||
|
||||
- name: Run ./ci/steps/build-docker-image.sh
|
||||
uses: ./ci/images/centos7
|
||||
with:
|
||||
args: ./ci/steps/build-docker-image.sh
|
||||
run: ./ci/steps/build-docker-image.sh
|
||||
|
||||
- name: Upload release image
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
name: publish
|
||||
|
||||
on:
|
||||
# Shows the manual trigger in GitHub UI
|
||||
# helpful as a back-up in case the GitHub Actions Workflow fails
|
||||
workflow_dispatch:
|
||||
|
||||
release:
|
||||
types: [published]
|
||||
|
||||
|
@ -29,3 +33,19 @@ jobs:
|
|||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
|
||||
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
|
||||
|
||||
homebrew:
|
||||
# The newest version of code-server needs to be available on npm when this runs
|
||||
# otherwise, it will 404 and won't open a PR to bump version on homebrew/homebrew-core
|
||||
needs: npm
|
||||
runs-on: macos-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Configure git
|
||||
run: |
|
||||
git config user.name github-actions
|
||||
git config user.email github-actions@github.com
|
||||
- name: Bump code-server homebrew version
|
||||
env:
|
||||
HOMEBREW_GITHUB_API_TOKEN: ${{secrets.HOMEBREW_GITHUB_API_TOKEN}}
|
||||
run: ./ci/steps/brew-bump.sh
|
||||
|
|
|
@ -14,3 +14,7 @@ node-*
|
|||
/plugins
|
||||
/lib/coder-cloud-agent
|
||||
.home
|
||||
coverage
|
||||
**/.DS_Store
|
||||
test/e2e/videos
|
||||
test/e2e/screenshots
|
||||
|
|
|
@ -50,7 +50,7 @@
|
|||
{
|
||||
"file": "src/node/heart.ts",
|
||||
"line": 7,
|
||||
"description": "code-server's heart beats to indicate recent activity.\n\nAlso documented here: [https://github.com/cdr/code-server/blob/master/doc/FAQ.md#heartbeat-file](https://github.com/cdr/code-server/blob/master/doc/FAQ.md#heartbeat-file)"
|
||||
"description": "code-server's heart beats to indicate recent activity.\n\nAlso documented here: [https://github.com/cdr/code-server/blob/master/docs/FAQ.md#heartbeat-file](https://github.com/cdr/code-server/blob/master/docs/FAQ.md#heartbeat-file)"
|
||||
},
|
||||
{
|
||||
"file": "src/node/socket.ts",
|
||||
|
@ -80,12 +80,12 @@
|
|||
{
|
||||
"file": "src/node/routes/domainProxy.ts",
|
||||
"line": 18,
|
||||
"description": "code-server provides a built-in proxy to help in developing web-based applications. This is the code for the domain-based proxy.\n\nAlso documented here: [https://github.com/cdr/code-server/blob/master/doc/FAQ.md#how-do-i-securely-access-web-services](https://github.com/cdr/code-server/blob/master/doc/FAQ.md#how-do-i-securely-access-web-services)"
|
||||
"description": "code-server provides a built-in proxy to help in developing web-based applications. This is the code for the domain-based proxy.\n\nAlso documented here: [https://github.com/cdr/code-server/blob/master/docs/FAQ.md#how-do-i-securely-access-web-services](https://github.com/cdr/code-server/blob/master/docs/FAQ.md#how-do-i-securely-access-web-services)"
|
||||
},
|
||||
{
|
||||
"file": "src/node/routes/pathProxy.ts",
|
||||
"line": 19,
|
||||
"description": "Here is the path-based version of the proxy.\n\nAlso documented here: [https://github.com/cdr/code-server/blob/master/doc/FAQ.md#how-do-i-securely-access-web-services](https://github.com/cdr/code-server/blob/master/doc/FAQ.md#how-do-i-securely-access-web-services)"
|
||||
"description": "Here is the path-based version of the proxy.\n\nAlso documented here: [https://github.com/cdr/code-server/blob/master/docs/FAQ.md#how-do-i-securely-access-web-services](https://github.com/cdr/code-server/blob/master/docs/FAQ.md#how-do-i-securely-access-web-services)"
|
||||
},
|
||||
{
|
||||
"file": "src/node/proxy.ts",
|
||||
|
@ -95,7 +95,7 @@
|
|||
{
|
||||
"file": "src/node/routes/health.ts",
|
||||
"line": 5,
|
||||
"description": "A simple endpoint that lets you see if code-server is up.\n\nAlso documented here: [https://github.com/cdr/code-server/blob/master/doc/FAQ.md#healthz-endpoint](https://github.com/cdr/code-server/blob/master/doc/FAQ.md#healthz-endpoint)"
|
||||
"description": "A simple endpoint that lets you see if code-server is up.\n\nAlso documented here: [https://github.com/cdr/code-server/blob/master/docs/FAQ.md#healthz-endpoint](https://github.com/cdr/code-server/blob/master/docs/FAQ.md#healthz-endpoint)"
|
||||
},
|
||||
{
|
||||
"file": "src/node/routes/login.ts",
|
||||
|
@ -145,7 +145,7 @@
|
|||
{
|
||||
"directory": "lib/vscode",
|
||||
"line": 1,
|
||||
"description": "code-server makes use of VS Code's frontend web/remote support. Most of the modifications implement the remote server since that portion of the code is closed source and not released with VS Code.\n\nWe also have a few bug fixes and have added some features (like client-side extensions). See [https://github.com/cdr/code-server/blob/master/doc/CONTRIBUTING.md#modifications-to-vs-code](https://github.com/cdr/code-server/blob/master/doc/CONTRIBUTING.md#modifications-to-vs-code) for a list.\n\nWe make an effort to keep the modifications as few as possible."
|
||||
"description": "code-server makes use of VS Code's frontend web/remote support. Most of the modifications implement the remote server since that portion of the code is closed source and not released with VS Code.\n\nWe also have a few bug fixes and have added some features (like client-side extensions). See [https://github.com/cdr/code-server/blob/master/docs/CONTRIBUTING.md#modifications-to-vs-code](https://github.com/cdr/code-server/blob/master/docs/CONTRIBUTING.md#modifications-to-vs-code) for a list.\n\nWe make an effort to keep the modifications as few as possible."
|
||||
}
|
||||
]
|
||||
}
|
|
@ -20,7 +20,7 @@
|
|||
{
|
||||
"file": "src/node/app.ts",
|
||||
"line": 62,
|
||||
"description": "## That's it!\n\n\nThat's all there is to it! When this tour ends, your terminal session may stop, but just use `yarn watch` to start developing from here on out!\n\n\nIf you haven't already, be sure to check out these resources:\n- [Tour: Contributing](command:codetour.startTourByTitle?[\"Contributing\")\n- [Docs: FAQ.md](https://github.com/cdr/code-server/blob/master/doc/FAQ.md)\n- [Docs: CONTRIBUTING.md](https://github.com/cdr/code-server/blob/master/doc/CONTRIBUTING.md)\n- [Community: GitHub Discussions](https://github.com/cdr/code-server/discussions)\n- [Community: Slack](https://community.coder.com)"
|
||||
"description": "## That's it!\n\n\nThat's all there is to it! When this tour ends, your terminal session may stop, but just use `yarn watch` to start developing from here on out!\n\n\nIf you haven't already, be sure to check out these resources:\n- [Tour: Contributing](command:codetour.startTourByTitle?[\"Contributing\")\n- [Docs: FAQ.md](https://github.com/cdr/code-server/blob/master/docs/FAQ.md)\n- [Docs: CONTRIBUTING.md](https://github.com/cdr/code-server/blob/master/docs/CONTRIBUTING.md)\n- [Community: GitHub Discussions](https://github.com/cdr/code-server/discussions)\n- [Community: Slack](https://community.coder.com)"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
37
README.md
37
README.md
|
@ -1,8 +1,11 @@
|
|||
# code-server · [!["GitHub Discussions"](https://img.shields.io/badge/%20GitHub-%20Discussions-gray.svg?longCache=true&logo=github&colorB=purple)](https://github.com/cdr/code-server/discussions) [!["Join us on Slack"](https://img.shields.io/badge/join-us%20on%20slack-gray.svg?longCache=true&logo=slack&colorB=brightgreen)](https://cdr.co/join-community) [![Twitter Follow](https://img.shields.io/twitter/follow/CoderHQ?label=%40CoderHQ&style=social)](https://twitter.com/coderhq)
|
||||
|
||||
![Lines](https://img.shields.io/badge/Coverage-51.47%25-green.svg)
|
||||
[![See latest docs](https://img.shields.io/static/v1?label=Docs&message=see%20latest%20&color=blue)](https://github.com/cdr/code-server/tree/v3.9.3/docs)
|
||||
|
||||
Run [VS Code](https://github.com/Microsoft/vscode) on any machine anywhere and access it in the browser.
|
||||
|
||||
![Screenshot](./doc/assets/screenshot.png)
|
||||
![Screenshot](./docs/assets/screenshot.png)
|
||||
|
||||
## Highlights
|
||||
|
||||
|
@ -10,12 +13,22 @@ Run [VS Code](https://github.com/Microsoft/vscode) on any machine anywhere and a
|
|||
- Use cloud servers to speed up tests, compilations, downloads, and more
|
||||
- Preserve battery life when you're on the go; all intensive tasks run on your server
|
||||
|
||||
## Requirements
|
||||
|
||||
For a good experience, we recommend at least:
|
||||
|
||||
- 1 GB of RAM
|
||||
- 2 cores
|
||||
|
||||
You can use whatever linux distribution floats your boat but in our [guide](./docs/guide.md) we assume Debian on Google Cloud.
|
||||
|
||||
## Getting Started
|
||||
|
||||
There are two ways to get started:
|
||||
There are three ways you can get started:
|
||||
|
||||
1. Using the [install script](./install.sh), which automates most of the process. The script uses the system package manager (if possible)
|
||||
2. Manually installing code-server; see [Installation](./doc/install.md) for instructions applicable to most use cases
|
||||
2. Manually installing code-server; see [Installation](./docs/install.md) for instructions applicable to most use cases
|
||||
3. Use our one-click buttons and guides to [deploy code-server to a popular cloud provider](https://github.com/cdr/deploy-code-server) ⚡
|
||||
|
||||
If you choose to use the install script, you can preview what occurs during the install process:
|
||||
|
||||
|
@ -31,9 +44,9 @@ curl -fsSL https://code-server.dev/install.sh | sh
|
|||
|
||||
When done, the install script prints out instructions for running and starting code-server.
|
||||
|
||||
We also have an in-depth [setup and configuration](./doc/guide.md) guide.
|
||||
We also have an in-depth [setup and configuration](./docs/guide.md) guide.
|
||||
|
||||
### Cloud Program ☁️
|
||||
### code-server --link
|
||||
|
||||
We're working on a cloud platform that makes deploying and managing code-server easier.
|
||||
Consider running code-server with the beta flag `--link` if you don't want to worry about
|
||||
|
@ -44,26 +57,20 @@ Consider running code-server with the beta flag `--link` if you don't want to wo
|
|||
|
||||
```bash
|
||||
$ code-server --link
|
||||
Proxying code-server to Coder Cloud, you can access your IDE at https://valmar-jon.cdr.co
|
||||
Proxying code-server, you can access your IDE at https://valmar-jon.cdr.co
|
||||
```
|
||||
|
||||
## FAQ
|
||||
|
||||
See [./doc/FAQ.md](./doc/FAQ.md).
|
||||
See [./docs/FAQ.md](./docs/FAQ.md).
|
||||
|
||||
## Want to help?
|
||||
|
||||
See [CONTRIBUTING](./doc/CONTRIBUTING.md) for details.
|
||||
See [CONTRIBUTING](./docs/CONTRIBUTING.md) for details.
|
||||
|
||||
## Hiring
|
||||
|
||||
We ([@cdr](https://github.com/cdr)) are looking for engineers to help [maintain
|
||||
code-server](https://jobs.lever.co/coder/e40becde-2cbd-4885-9029-e5c7b0a734b8), innovate on open source, and streamline dev workflows.
|
||||
|
||||
Our main office is in Austin, Texas. Remote is ok as long as
|
||||
you're in North America or Europe.
|
||||
|
||||
Please get in [touch](mailto:jobs@coder.com) with your resume/GitHub if interested.
|
||||
Interested in [working at Coder](https://coder.com)? Check out [our open positions](https://jobs.lever.co/coder)!
|
||||
|
||||
## For Organizations
|
||||
|
||||
|
|
50
ci/README.md
50
ci/README.md
|
@ -12,20 +12,13 @@ Any file or directory in this subdirectory should be documented here.
|
|||
|
||||
## Publishing a release
|
||||
|
||||
Make sure you have `$GITHUB_TOKEN` set and [hub](https://github.com/github/hub) installed.
|
||||
|
||||
1. Update the version of code-server and make a PR.
|
||||
1. Update in `package.json`
|
||||
2. Update in [./doc/install.md](../doc/install.md)
|
||||
3. Update in [./ci/helm-chart/README.md](../ci/helm-chart/README.md)
|
||||
- Remember to update the chart version as well on top of appVersion in `Chart.yaml`.
|
||||
- Run `rg -g '!yarn.lock' -g '!*.svg' '3\.7\.5'` to ensure all values have been
|
||||
changed. Replace the numbers as needed.
|
||||
1. Run `yarn release:prep` and type in the new version i.e. 3.8.1
|
||||
2. GitHub actions will generate the `npm-package`, `release-packages` and `release-images` artifacts.
|
||||
1. You do not have to wait for these.
|
||||
3. Run `yarn release:github-draft` to create a GitHub draft release from the template with
|
||||
the updated version.
|
||||
1. Summarize the major changes in the release notes and link to the relevant issues.
|
||||
2. Change the @ to target the version branch. Example: `v3.9.0 @ Target: v3.9.0`
|
||||
4. Wait for the artifacts in step 2 to build.
|
||||
5. Run `yarn release:github-assets` to download the `release-packages` artifact.
|
||||
- It will upload them to the draft release.
|
||||
|
@ -40,26 +33,43 @@ Make sure you have `$GITHUB_TOKEN` set and [hub](https://github.com/github/hub)
|
|||
9. Update the AUR package.
|
||||
- Instructions on updating the AUR package are at [cdr/code-server-aur](https://github.com/cdr/code-server-aur).
|
||||
10. Wait for the npm package to be published.
|
||||
11. Update the homebrew package.
|
||||
- Send a pull request to [homebrew-core](https://github.com/Homebrew/homebrew-core) with the URL in the [formula](https://github.com/Homebrew/homebrew-core/blob/master/Formula/code-server.rb) updated.
|
||||
11. Update the [homebrew package](https://github.com/Homebrew/homebrew-core/blob/master/Formula/code-server.rb).
|
||||
1. Install [homebrew](https://brew.sh/)
|
||||
2. Run `brew bump-formula-pr --version=3.8.1 code-server` and update the version accordingly. This will bump the version and open a PR. Note: this will only work once the version is published on npm.
|
||||
|
||||
## Updating Code Coverage in README
|
||||
|
||||
Currently, we run a command to manually generate the code coverage shield. Follow these steps:
|
||||
|
||||
1. Run `yarn test:unit` and make sure all the tests are passing
|
||||
2. Run `yarn badges`
|
||||
3. Go into the README and change the color from `red` to `green` in this line:
|
||||
|
||||
```
|
||||
![Lines](https://img.shields.io/badge/Coverage-46.71%25-red.svg)
|
||||
```
|
||||
|
||||
NOTE: we have to manually change the color because the default is red if coverage is less than 80. See code [here](https://github.com/olavoparno/istanbul-badges-readme/blob/develop/src/editor.ts#L24-L33).
|
||||
|
||||
## dev
|
||||
|
||||
This directory contains scripts used for the development of code-server.
|
||||
|
||||
- [./ci/dev/image](./dev/image)
|
||||
- See [./doc/CONTRIBUTING.md](../doc/CONTRIBUTING.md) for docs on the development container.
|
||||
- See [./docs/CONTRIBUTING.md](../docs/CONTRIBUTING.md) for docs on the development container.
|
||||
- [./ci/dev/fmt.sh](./dev/fmt.sh) (`yarn fmt`)
|
||||
- Runs formatters.
|
||||
- [./ci/dev/lint.sh](./dev/lint.sh) (`yarn lint`)
|
||||
- Runs linters.
|
||||
- [./ci/dev/test.sh](./dev/test.sh) (`yarn test`)
|
||||
- Runs tests.
|
||||
- [./ci/dev/test-unit.sh](./dev/test-unit.sh) (`yarn test:unit`)
|
||||
- Runs unit tests.
|
||||
- [./ci/dev/test-e2e.sh](./dev/test-e2e.sh) (`yarn test:e2e`)
|
||||
- Runs end-to-end tests.
|
||||
- [./ci/dev/ci.sh](./dev/ci.sh) (`yarn ci`)
|
||||
- Runs `yarn fmt`, `yarn lint` and `yarn test`.
|
||||
- [./ci/dev/watch.ts](./dev/watch.ts) (`yarn watch`)
|
||||
- Starts a process to build and launch code-server and restart on any code changes.
|
||||
- Example usage in [./doc/CONTRIBUTING.md](../doc/CONTRIBUTING.md).
|
||||
- Example usage in [./docs/CONTRIBUTING.md](../docs/CONTRIBUTING.md).
|
||||
- [./ci/dev/gen_icons.sh](./ci/dev/gen_icons.sh) (`yarn icons`)
|
||||
- Generates the various icons from a single `.svg` favicon in
|
||||
`src/browser/media/favicon.svg`.
|
||||
|
@ -123,11 +133,13 @@ This directory contains the scripts used in CI.
|
|||
Helps avoid clobbering the CI configuration.
|
||||
|
||||
- [./steps/fmt.sh](./steps/fmt.sh)
|
||||
- Runs `yarn fmt` after ensuring VS Code is patched.
|
||||
- Runs `yarn fmt`.
|
||||
- [./steps/lint.sh](./steps/lint.sh)
|
||||
- Runs `yarn lint` after ensuring VS Code is patched.
|
||||
- [./steps/test.sh](./steps/test.sh)
|
||||
- Runs `yarn test` after ensuring VS Code is patched.
|
||||
- Runs `yarn lint`.
|
||||
- [./steps/test-unit.sh](./steps/test-unit.sh)
|
||||
- Runs `yarn test:unit`.
|
||||
- [./steps/test-e2e.sh](./steps/test-e2e.sh)
|
||||
- Runs `yarn test:e2e`.
|
||||
- [./steps/release.sh](./steps/release.sh)
|
||||
- Runs the release process.
|
||||
- Generates the npm package at `./release`.
|
||||
|
|
|
@ -8,6 +8,12 @@ main() {
|
|||
cd "$(dirname "${0}")/../.."
|
||||
source ./ci/lib.sh
|
||||
|
||||
# Allow us to override architecture
|
||||
# we use this for our Linux ARM64 cross compile builds
|
||||
if [ "$#" -eq 1 ] && [ "$1" ]; then
|
||||
ARCH=$1
|
||||
fi
|
||||
|
||||
mkdir -p release-packages
|
||||
|
||||
release_archive
|
||||
|
@ -40,7 +46,7 @@ release_gcp() {
|
|||
# Generates deb and rpm packages.
|
||||
release_nfpm() {
|
||||
local nfpm_config
|
||||
nfpm_config="$(envsubst < ./ci/build/nfpm.yaml)"
|
||||
nfpm_config="$(envsubst <./ci/build/nfpm.yaml)"
|
||||
|
||||
# The underscores are convention for .deb.
|
||||
nfpm pkg -f <(echo "$nfpm_config") --target "release-packages/code-server_${VERSION}_$ARCH.deb"
|
||||
|
|
|
@ -25,12 +25,6 @@ main() {
|
|||
rsync README.md "$RELEASE_PATH"
|
||||
rsync LICENSE.txt "$RELEASE_PATH"
|
||||
rsync ./lib/vscode/ThirdPartyNotices.txt "$RELEASE_PATH"
|
||||
|
||||
# code-server exports types which can be imported and used by plugins. Those
|
||||
# types import ipc.d.ts but it isn't included in the final vscode build so
|
||||
# we'll copy it ourselves here.
|
||||
mkdir -p "$RELEASE_PATH/lib/vscode/src/vs/server"
|
||||
rsync ./lib/vscode/src/vs/server/ipc.d.ts "$RELEASE_PATH/lib/vscode/src/vs/server"
|
||||
}
|
||||
|
||||
bundle_code_server() {
|
||||
|
@ -45,11 +39,11 @@ bundle_code_server() {
|
|||
|
||||
# Add typings for plugins
|
||||
mkdir -p "$RELEASE_PATH/typings"
|
||||
rsync typings/pluginapi.d.ts"$RELEASE_PATH/typings"
|
||||
rsync typings/pluginapi.d.ts "$RELEASE_PATH/typings"
|
||||
|
||||
# Adds the commit to package.json
|
||||
jq --slurp '.[0] * .[1]' package.json <(
|
||||
cat << EOF
|
||||
cat <<EOF
|
||||
{
|
||||
"commit": "$(git rev-parse HEAD)",
|
||||
"scripts": {
|
||||
|
@ -57,7 +51,7 @@ bundle_code_server() {
|
|||
}
|
||||
}
|
||||
EOF
|
||||
) > "$RELEASE_PATH/package.json"
|
||||
) >"$RELEASE_PATH/package.json"
|
||||
rsync yarn.lock "$RELEASE_PATH"
|
||||
rsync ci/build/npm-postinstall.sh "$RELEASE_PATH/postinstall.sh"
|
||||
|
||||
|
@ -83,23 +77,24 @@ bundle_vscode() {
|
|||
rsync "$VSCODE_SRC_PATH/extensions/yarn.lock" "$VSCODE_OUT_PATH/extensions"
|
||||
rsync "$VSCODE_SRC_PATH/extensions/postinstall.js" "$VSCODE_OUT_PATH/extensions"
|
||||
|
||||
mkdir -p "$VSCODE_OUT_PATH/resources/linux"
|
||||
mkdir -p "$VSCODE_OUT_PATH/resources/"{linux,web}
|
||||
rsync "$VSCODE_SRC_PATH/resources/linux/code.png" "$VSCODE_OUT_PATH/resources/linux/code.png"
|
||||
rsync "$VSCODE_SRC_PATH/resources/web/callback.html" "$VSCODE_OUT_PATH/resources/web/callback.html"
|
||||
|
||||
# Adds the commit and date to product.json
|
||||
jq --slurp '.[0] * .[1]' "$VSCODE_SRC_PATH/product.json" <(
|
||||
cat << EOF
|
||||
cat <<EOF
|
||||
{
|
||||
"commit": "$(git rev-parse HEAD)",
|
||||
"date": $(jq -n 'now | todate')
|
||||
}
|
||||
EOF
|
||||
) > "$VSCODE_OUT_PATH/product.json"
|
||||
) >"$VSCODE_OUT_PATH/product.json"
|
||||
|
||||
# We remove the scripts field so that later on we can run
|
||||
# yarn to fetch node_modules if necessary without build scripts running.
|
||||
# We cannot use --no-scripts because we still want dependent package scripts to run.
|
||||
jq 'del(.scripts)' < "$VSCODE_SRC_PATH/package.json" > "$VSCODE_OUT_PATH/package.json"
|
||||
jq 'del(.scripts)' <"$VSCODE_SRC_PATH/package.json" >"$VSCODE_OUT_PATH/package.json"
|
||||
|
||||
pushd "$VSCODE_OUT_PATH"
|
||||
symlink_asar
|
||||
|
|
|
@ -12,7 +12,7 @@ main() {
|
|||
# we use the same version it's using so we instead run a script with yarn that
|
||||
# will print the path to node.
|
||||
local node_path
|
||||
node_path="$(yarn -s node <<< 'console.info(process.execPath)')"
|
||||
node_path="$(yarn -s node <<<'console.info(process.execPath)')"
|
||||
|
||||
mkdir -p "$RELEASE_PATH/bin"
|
||||
rsync ./ci/build/code-server.sh "$RELEASE_PATH/bin/code-server"
|
||||
|
|
|
@ -11,9 +11,9 @@ _realpath() {
|
|||
cd "$(dirname "$script")"
|
||||
|
||||
while [ -L "$(basename "$script")" ]; do
|
||||
if [ -L "./node" ] && [ -L "./code-server" ] &&
|
||||
[ -f "package.json" ] &&
|
||||
cat package.json | grep -q '^ "name": "code-server",$'; then
|
||||
if [ -L "./node" ] && [ -L "./code-server" ] \
|
||||
&& [ -f "package.json" ] \
|
||||
&& cat package.json | grep -q '^ "name": "code-server",$'; then
|
||||
echo "***** Please use the script in bin/code-server instead!" >&2
|
||||
echo "***** This script will soon be removed!" >&2
|
||||
echo "***** See the release notes at https://github.com/cdr/code-server/releases/tag/v3.4.0" >&2
|
||||
|
|
|
@ -10,10 +10,16 @@ description: |
|
|||
vendor: "Coder"
|
||||
homepage: "https://github.com/cdr/code-server"
|
||||
license: "MIT"
|
||||
files:
|
||||
./ci/build/code-server-nfpm.sh: /usr/bin/code-server
|
||||
./ci/build/code-server@.service: /usr/lib/systemd/system/code-server@.service
|
||||
# Only included for backwards compat with previous releases that shipped
|
||||
# the user service. See #1997
|
||||
./ci/build/code-server-user.service: /usr/lib/systemd/user/code-server.service
|
||||
./release-standalone/**/*: "/usr/lib/code-server/"
|
||||
|
||||
contents:
|
||||
- src: ./ci/build/code-server-nfpm.sh
|
||||
dst: /usr/bin/code-server
|
||||
|
||||
- src: ./ci/build/code-server@.service
|
||||
dst: /usr/lib/systemd/system/code-server@.service
|
||||
|
||||
- src: ./ci/build/code-server-user.service
|
||||
dst: /usr/lib/systemd/user/code-server.service
|
||||
|
||||
- src: ./release-standalone/*
|
||||
dst: /usr/lib/code-server/
|
||||
|
|
|
@ -33,7 +33,7 @@ main() {
|
|||
|
||||
if ! vscode_yarn; then
|
||||
echo "You may not have the required dependencies to build the native modules."
|
||||
echo "Please see https://github.com/cdr/code-server/blob/master/doc/npm.md"
|
||||
echo "Please see https://github.com/cdr/code-server/blob/master/docs/npm.md"
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
|
|
@ -10,7 +10,7 @@ main() {
|
|||
hub release create \
|
||||
--file - \
|
||||
-t "$(git rev-parse HEAD)" \
|
||||
--draft "${assets[@]}" "v$VERSION" << EOF
|
||||
--draft "v$VERSION" <<EOF
|
||||
v$VERSION
|
||||
|
||||
VS Code v$(vscode_version)
|
||||
|
@ -20,10 +20,28 @@ maintains all user data in \`~/.local/share/code-server\` so that it is preserve
|
|||
installations.
|
||||
|
||||
## New Features
|
||||
- ⭐ Summarize new features here with references to issues
|
||||
|
||||
⭐ Summarize new features here with references to issues
|
||||
|
||||
- item
|
||||
|
||||
## Bug Fixes
|
||||
- ⭐ Summarize bug fixes here with references to issues
|
||||
|
||||
⭐ Summarize bug fixes here with references to issues
|
||||
|
||||
- item
|
||||
|
||||
## Documentation
|
||||
|
||||
⭐ Summarize doc changes here with references to issues
|
||||
|
||||
- item
|
||||
|
||||
## Development
|
||||
|
||||
⭐ Summarize development/testing changes here with references to issues
|
||||
|
||||
- item
|
||||
|
||||
Cheers! 🍻
|
||||
EOF
|
||||
|
|
|
@ -0,0 +1,115 @@
|
|||
#!/usr/bin/env bash
|
||||
# Description: This is a script to make the release process easier
|
||||
# Run it with `yarn release:prep` and it will do the following:
|
||||
# 1. Check that you have a $GITHUB_TOKEN set and hub installed
|
||||
# 2. Update the version of code-server (package.json, docs, etc.)
|
||||
# 3. Update the code coverage badge in the README
|
||||
# 4. Open a draft PR using the release_template.md and view in browser
|
||||
# If you want to perform a dry run of this script run DRY_RUN=1 yarn release:prep
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
if [ "${DRY_RUN-}" = 1 ]; then
|
||||
echo "Performing a dry run..."
|
||||
CMD="echo"
|
||||
else
|
||||
CMD=''
|
||||
fi
|
||||
|
||||
cd "$(dirname "$0")/../.."
|
||||
|
||||
# Check that $GITHUB_TOKEN is set
|
||||
if [[ -z ${GITHUB_TOKEN-} ]]; then
|
||||
echo "We couldn't find an environment variable under GITHUB_TOKEN."
|
||||
echo "This is needed for our scripts that use hub."
|
||||
echo -e "See docs regarding GITHUB_TOKEN here under 'GitHub OAuth authentication': https://hub.github.com/hub.1.html"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check that hub is installed
|
||||
if ! command -v hub &>/dev/null; then
|
||||
echo "hub could not be found."
|
||||
echo "We use this with the release-github-draft.sh and release-github-assets.sh scripts."
|
||||
echo -e "See docs here: https://github.com/github/hub#installation"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check that they have jq installed
|
||||
if ! command -v jq &>/dev/null; then
|
||||
echo "jq could not be found."
|
||||
echo "We use this to parse the package.json and grab the current version of code-server."
|
||||
echo -e "See docs here: https://stedolan.github.io/jq/download/"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check that they have rg installed
|
||||
if ! command -v rg &>/dev/null; then
|
||||
echo "rg could not be found."
|
||||
echo "We use this when updating files across the codebase."
|
||||
echo -e "See docs here: https://github.com/BurntSushi/ripgrep#installation"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check that they have sd installed
|
||||
if ! command -v sd &>/dev/null; then
|
||||
echo "sd could not be found."
|
||||
echo "We use this when updating files across the codebase."
|
||||
echo -e "See docs here: https://github.com/chmln/sd#installation"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check that they have node installed
|
||||
if ! command -v node &>/dev/null; then
|
||||
echo "node could not be found."
|
||||
echo "That's surprising..."
|
||||
echo "We use it in this script for getting the package.json version"
|
||||
echo -e "See docs here: https://nodejs.org/en/download/"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Note: we need to set upstream as well or the gh pr create step will fail
|
||||
# See: https://github.com/cli/cli/issues/575
|
||||
CURRENT_BRANCH=$(git branch | grep '\*' | cut -d' ' -f2-)
|
||||
if [[ -z $(git config "branch.${CURRENT_BRANCH}.remote") ]]; then
|
||||
echo "Doesn't look like you've pushed this branch to remote"
|
||||
# Note: we need to set upstream as well or the gh pr create step will fail
|
||||
# See: https://github.com/cli/cli/issues/575
|
||||
echo "Please set the upstream and then run the script"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# credit to jakwuh for this solution
|
||||
# https://gist.github.com/DarrenN/8c6a5b969481725a4413#gistcomment-1971123
|
||||
CODE_SERVER_CURRENT_VERSION=$(node -pe "require('./package.json').version")
|
||||
# Ask which version we should update to
|
||||
# In the future, we'll automate this and determine the latest version automatically
|
||||
echo "Current version: ${CODE_SERVER_CURRENT_VERSION}"
|
||||
# The $'\n' adds a line break. See: https://stackoverflow.com/a/39581815/3015595
|
||||
read -r -p "What version of code-server do you want to update to?"$'\n' CODE_SERVER_VERSION_TO_UPDATE
|
||||
|
||||
echo -e "Great! We'll prep a PR for updating to $CODE_SERVER_VERSION_TO_UPDATE\n"
|
||||
$CMD rg -g '!yarn.lock' -g '!*.svg' --files-with-matches --fixed-strings "${CODE_SERVER_CURRENT_VERSION}" | $CMD xargs sd "$CODE_SERVER_CURRENT_VERSION" "$CODE_SERVER_VERSION_TO_UPDATE"
|
||||
|
||||
# Ensure the tests are passing and code coverage is up-to-date
|
||||
echo -e "Running unit tests and updating code coverage...\n"
|
||||
$CMD yarn test:unit
|
||||
# Updates the Lines badge in the README
|
||||
$CMD yarn badges
|
||||
# Updates the svg to be green for the badge
|
||||
$CMD sd "red.svg" "green.svg" ./README.md
|
||||
|
||||
$CMD git commit -am "chore(release): bump version to $CODE_SERVER_VERSION_TO_UPDATE"
|
||||
|
||||
# This runs from the root so that's why we use this path vs. ../../
|
||||
RELEASE_TEMPLATE_STRING=$(cat ./.github/PULL_REQUEST_TEMPLATE/release_template.md)
|
||||
|
||||
echo -e "\nOpening a draft PR on GitHub"
|
||||
# To read about these flags, visit the docs: https://cli.github.com/manual/gh_pr_create
|
||||
$CMD gh pr create --base main --title "release: $CODE_SERVER_VERSION_TO_UPDATE" --body "$RELEASE_TEMPLATE_STRING" --reviewer @cdr/code-server-reviewers --repo cdr/code-server --draft
|
||||
|
||||
# Open PR in browser
|
||||
$CMD gh pr view --web
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -12,11 +12,12 @@ main() {
|
|||
|
||||
echo "Testing standalone release."
|
||||
|
||||
./release-standalone/bin/code-server --extensions-dir "$EXTENSIONS_DIR" --install-extension ms-python.python
|
||||
# Note: using a basic theme extension because it doesn't update often and is more reliable for testing
|
||||
./release-standalone/bin/code-server --extensions-dir "$EXTENSIONS_DIR" --install-extension wesbos.theme-cobalt2
|
||||
local installed_extensions
|
||||
installed_extensions="$(./release-standalone/bin/code-server --extensions-dir "$EXTENSIONS_DIR" --list-extensions 2>&1)"
|
||||
# We use grep as ms-python.python may have dependency extensions that change.
|
||||
if ! echo "$installed_extensions" | grep -q "ms-python.python"; then
|
||||
# We use grep as wesbos.theme-cobalt2 may have dependency extensions that change.
|
||||
if ! echo "$installed_extensions" | grep -q "wesbos.theme-cobalt2"; then
|
||||
echo "Unexpected output from listing extensions:"
|
||||
echo "$installed_extensions"
|
||||
exit 1
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
|
||||
# Prevents integration with moderate or higher vulnerabilities
|
||||
# Docs: https://github.com/IBM/audit-ci#options
|
||||
yarn audit-ci --moderate
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -6,7 +6,8 @@ main() {
|
|||
|
||||
yarn fmt
|
||||
yarn lint
|
||||
yarn test
|
||||
yarn _audit
|
||||
yarn test:unit
|
||||
}
|
||||
|
||||
main "$@"
|
||||
|
|
|
@ -4,8 +4,6 @@ set -euo pipefail
|
|||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
|
||||
shfmt -i 2 -w -sr $(git ls-files "*.sh" | grep -v "lib/vscode")
|
||||
|
||||
local prettierExts
|
||||
prettierExts=(
|
||||
"*.js"
|
||||
|
@ -18,17 +16,19 @@ main() {
|
|||
"*.toml"
|
||||
"*.yaml"
|
||||
"*.yml"
|
||||
"*.sh"
|
||||
)
|
||||
prettier --write --loglevel=warn $(
|
||||
git ls-files "${prettierExts[@]}" | grep -v "lib/vscode" | grep -v 'helm-chart'
|
||||
)
|
||||
|
||||
doctoc --title '# FAQ' doc/FAQ.md > /dev/null
|
||||
doctoc --title '# Setup Guide' doc/guide.md > /dev/null
|
||||
doctoc --title '# Install' doc/install.md > /dev/null
|
||||
doctoc --title '# npm Install Requirements' doc/npm.md > /dev/null
|
||||
doctoc --title '# Contributing' doc/CONTRIBUTING.md > /dev/null
|
||||
doctoc --title '# iPad' doc/ipad.md > /dev/null
|
||||
doctoc --title '# FAQ' docs/FAQ.md >/dev/null
|
||||
doctoc --title '# Setup Guide' docs/guide.md >/dev/null
|
||||
doctoc --title '# Install' docs/install.md >/dev/null
|
||||
doctoc --title '# npm Install Requirements' docs/npm.md >/dev/null
|
||||
doctoc --title '# Contributing' docs/CONTRIBUTING.md >/dev/null
|
||||
doctoc --title '# Contributor Covenant Code of Conduct' docs/CODE_OF_CONDUCT.md >/dev/null
|
||||
doctoc --title '# iPad' docs/ipad.md >/dev/null
|
||||
|
||||
if [[ ${CI-} && $(git ls-files --other --modified --exclude-standard) ]]; then
|
||||
echo "Files need generation or are formatted incorrectly:"
|
||||
|
|
|
@ -14,10 +14,31 @@ main() {
|
|||
# -background defaults to white but we want it transparent.
|
||||
# https://imagemagick.org/script/command-line-options.php#background
|
||||
convert -quiet -background transparent -resize 256x256 favicon.svg favicon.ico
|
||||
# We do not generate the pwa-icon from the favicon as they are slightly different
|
||||
# designs and sizes.
|
||||
# See favicon.afdesign and #2401 for details on the differences.
|
||||
convert -quiet -background transparent -resize 192x192 pwa-icon.png pwa-icon-192.png
|
||||
convert -quiet -background transparent -resize 512x512 pwa-icon.png pwa-icon-512.png
|
||||
|
||||
# We use -quiet above to avoid https://github.com/ImageMagick/ImageMagick/issues/884
|
||||
|
||||
# The following adds dark mode support for the favicon as favicon-dark-support.svg
|
||||
# There is no similar capability for pwas or .ico so we can only add support to the svg.
|
||||
favicon_dark_style="<style>
|
||||
@media (prefers-color-scheme: dark) {
|
||||
* {
|
||||
fill: white;
|
||||
}
|
||||
}
|
||||
</style>"
|
||||
# See https://stackoverflow.com/a/22901380/4283659
|
||||
# This escapes all newlines so that sed will accept them.
|
||||
favicon_dark_style="$(printf "%s\n" "$favicon_dark_style" | sed -e ':a' -e 'N' -e '$!ba' -e 's/\n/\\n/g')"
|
||||
sed "$(
|
||||
cat -n <<EOF
|
||||
s%<rect id="favicon"%$favicon_dark_style<rect id="favicon"%
|
||||
EOF
|
||||
)" favicon.svg >favicon-dark-support.svg
|
||||
}
|
||||
|
||||
main "$@"
|
||||
|
|
|
@ -6,9 +6,9 @@ main() {
|
|||
|
||||
eslint --max-warnings=0 --fix $(git ls-files "*.ts" "*.tsx" "*.js" | grep -v "lib/vscode")
|
||||
stylelint $(git ls-files "*.css" | grep -v "lib/vscode")
|
||||
tsc --noEmit
|
||||
tsc --noEmit --skipLibCheck
|
||||
shellcheck -e SC2046,SC2164,SC2154,SC1091,SC1090,SC2002 $(git ls-files "*.sh" | grep -v "lib/vscode")
|
||||
if command -v helm && helm kubeval --help > /dev/null; then
|
||||
if command -v helm && helm kubeval --help >/dev/null; then
|
||||
helm kubeval ci/helm-chart
|
||||
fi
|
||||
|
||||
|
|
|
@ -5,6 +5,11 @@ main() {
|
|||
cd "$(dirname "$0")/../.."
|
||||
source ./ci/lib.sh
|
||||
|
||||
# This installs the dependencies needed for testing
|
||||
cd test
|
||||
yarn
|
||||
cd ..
|
||||
|
||||
cd lib/vscode
|
||||
yarn ${CI+--frozen-lockfile}
|
||||
|
||||
|
|
|
@ -1,12 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
|
||||
cd ./lib/vscode
|
||||
git add -A
|
||||
git reset --hard
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -0,0 +1,21 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
# We must keep jest in a sub-directory. See ../../test/package.json for more
|
||||
# information. We must also run it from the root otherwise coverage will not
|
||||
# include our source files.
|
||||
if [[ -z ${PASSWORD-} ]] || [[ -z ${CODE_SERVER_ADDRESS-} ]]; then
|
||||
echo "The end-to-end testing suites rely on your local environment"
|
||||
echo -e "\n"
|
||||
echo "Please set the following environment variables locally:"
|
||||
echo " \$PASSWORD"
|
||||
echo " \$CODE_SERVER_ADDRESS"
|
||||
echo -e "\n"
|
||||
exit 1
|
||||
fi
|
||||
CS_DISABLE_PLUGINS=true ./test/node_modules/.bin/jest "$@" --config ./test/jest.e2e.config.ts --runInBand
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -0,0 +1,15 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
cd test/unit/test-plugin
|
||||
make -s out/index.js
|
||||
# We must keep jest in a sub-directory. See ../../test/package.json for more
|
||||
# information. We must also run it from the root otherwise coverage will not
|
||||
# include our source files.
|
||||
cd "$OLDPWD"
|
||||
CS_DISABLE_PLUGINS=true ./test/node_modules/.bin/jest "$@"
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -1,13 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
|
||||
cd test/test-plugin
|
||||
make -s out/index.js
|
||||
cd "$OLDPWD"
|
||||
mocha -r ts-node/register ./test/*.test.ts "$@"
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -0,0 +1,121 @@
|
|||
#!/usr/bin/env bash
|
||||
# Description: This is a script to make the process of updating vscode versions easier
|
||||
# Run it with `yarn update:vscode` and it will do the following:
|
||||
# 1. Check that you have a remote called `vscode`
|
||||
# 2. Ask you which version you want to upgrade to
|
||||
# 3. Grab the exact version from the package.json i.e. 1.53.2
|
||||
# 4. Fetch the vscode remote branches to run the subtree update
|
||||
# 5. Run the subtree update and pull in the vscode update
|
||||
# 6. Commit the changes (including merge conflicts)
|
||||
# 7. Open a draft PR
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
# This function expects two arguments
|
||||
# 1. the vscode version we're updating to
|
||||
# 2. the list of merge conflict files
|
||||
make_pr_body() {
|
||||
local BODY="This PR updates vscode to $1
|
||||
|
||||
## TODOS
|
||||
|
||||
- [ ] test editor locally
|
||||
- [ ] test terminal locally
|
||||
- [ ] make notes about any significant changes in docs/CONTRIBUTING.md#notes-about-changes
|
||||
|
||||
## Files with conflicts (fix these)
|
||||
$2"
|
||||
echo "$BODY"
|
||||
}
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
|
||||
# Check if the remote exists
|
||||
# if it doesn't, we add it
|
||||
if ! git config remote.vscode.url >/dev/null; then
|
||||
echo "Could not find 'vscode' as a remote"
|
||||
echo "Adding with: git remote add vscode https://github.com/microsoft/vscode.git"
|
||||
git remote add vscode https://github.com/microsoft/vscode.git
|
||||
fi
|
||||
|
||||
# Ask which version we should update to
|
||||
# In the future, we'll automate this and grab the latest version automatically
|
||||
read -r -p "What version of VSCode would you like to update to? (i.e. 1.52) " VSCODE_VERSION_TO_UPDATE
|
||||
|
||||
# Check that this version exists
|
||||
if [[ -z $(git ls-remote --heads vscode release/"$VSCODE_VERSION_TO_UPDATE") ]]; then
|
||||
echo "Oops, that doesn't look like a valid version."
|
||||
echo "You entered: $VSCODE_VERSION_TO_UPDATE"
|
||||
echo "Verify that this branches exists here: https://github.com/microsoft/vscode/branches/all?query=release%2F$VSCODE_VERSION_TO_UPDATE"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Check that they have jq installed
|
||||
if ! command -v jq &>/dev/null; then
|
||||
echo "jq could not be found."
|
||||
echo "We use this when looking up the exact version to update to in the package.json in VS Code."
|
||||
echo -e "See docs here: https://stedolan.github.io/jq/download/"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Grab the exact version from package.json
|
||||
VSCODE_EXACT_VERSION=$(curl -s "https://raw.githubusercontent.com/microsoft/vscode/release/$VSCODE_VERSION_TO_UPDATE/package.json" | jq -r ".version")
|
||||
|
||||
echo -e "Great! We'll prep a PR for updating to $VSCODE_EXACT_VERSION\n"
|
||||
|
||||
# For some reason the subtree update doesn't work
|
||||
# unless we fetch all the branches
|
||||
echo -e "Fetching vscode branches..."
|
||||
echo -e "Note: this might take a while"
|
||||
git fetch vscode
|
||||
|
||||
# Check if GitHub CLI is installed
|
||||
if ! command -v gh &>/dev/null; then
|
||||
echo "GitHub CLI could not be found."
|
||||
echo "If you install it before you run this script next time, we'll open a draft PR for you!"
|
||||
echo -e "See docs here: https://github.com/cli/cli#installation\n"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Push branch to remote if not already pushed
|
||||
# If we don't do this, the opening a draft PR step won't work
|
||||
# because it will stop and ask where you want to push the branch
|
||||
CURRENT_BRANCH=$(git branch | grep '\*' | cut -d' ' -f2-)
|
||||
if [[ -z $(git config "branch.${CURRENT_BRANCH}.remote") ]]; then
|
||||
echo "Doesn't look like you've pushed this branch to remote"
|
||||
echo -e "Pushing now using: git push origin $CURRENT_BRANCH\n"
|
||||
# Note: we need to set upstream as well or the gh pr create step will fail
|
||||
# See: https://github.com/cli/cli/issues/575
|
||||
echo "Please set the upstream and re-run the script"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "Going to try to update vscode for you..."
|
||||
echo -e "Running: git subtree pull --prefix lib/vscode vscode release/${VSCODE_VERSION_TO_UPDATE} --squash\n"
|
||||
# Try to run subtree update command
|
||||
# Note: we add `|| true` because we want the script to keep running even if the squash fails
|
||||
# We know the squash fails everytime because there will always be merge conflicts
|
||||
git subtree pull --prefix lib/vscode vscode release/"${VSCODE_VERSION_TO_UPDATE}" --squash || true
|
||||
|
||||
# Get the files with conflicts before we commit them
|
||||
# so we can list them in the PR body as todo items
|
||||
CONFLICTS=$(git diff --name-only --diff-filter=U | while read -r line; do echo "- [ ] $line"; done)
|
||||
PR_BODY=$(make_pr_body "$VSCODE_EXACT_VERSION" "$CONFLICTS")
|
||||
|
||||
echo -e "\nForcing a commit with conflicts"
|
||||
echo "Note: this is intentional"
|
||||
echo "If we don't do this, code review is impossible."
|
||||
echo -e "For more info, see docs: docs/CONTRIBUTING.md#updating-vs-code\n"
|
||||
# We need --no-verify to skip the husky pre-commit hook
|
||||
# which fails because of the merge conflicts
|
||||
git add . && git commit -am "chore(vscode): update to $VSCODE_EXACT_VERSION" --no-verify
|
||||
|
||||
# Note: we can't open a draft PR unless their are changes.
|
||||
# Hence why we do this after the subtree update.
|
||||
echo "Opening a draft PR on GitHub"
|
||||
# To read about these flags, visit the docs: https://cli.github.com/manual/gh_pr_create
|
||||
gh pr create --base main --title "feat(vscode): update to version $VSCODE_EXACT_VERSION" --body "$PR_BODY" --reviewer @cdr/code-server-reviewers --repo cdr/code-server --draft
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -20,4 +20,4 @@ version: 1.0.3
|
|||
# This is the version number of the application being deployed. This version number should be
|
||||
# incremented each time you make changes to the application. Versions are not expected to
|
||||
# follow Semantic Versioning. They should reflect the version the application is using.
|
||||
appVersion: 3.8.0
|
||||
appVersion: 3.9.3
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# code-server
|
||||
|
||||
![Version: 1.0.0](https://img.shields.io/badge/Version-1.0.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 3.8.0](https://img.shields.io/badge/AppVersion-3.8.0-informational?style=flat-square)
|
||||
![Version: 1.0.0](https://img.shields.io/badge/Version-1.0.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 3.9.3](https://img.shields.io/badge/AppVersion-3.9.3-informational?style=flat-square)
|
||||
|
||||
[code-server](https://github.com/cdr/code-server) code-server is VS Code running
|
||||
on a remote server, accessible through the browser.
|
||||
|
@ -72,7 +72,7 @@ and their default values.
|
|||
| hostnameOverride | string | `""` | |
|
||||
| image.pullPolicy | string | `"Always"` | |
|
||||
| image.repository | string | `"codercom/code-server"` | |
|
||||
| image.tag | string | `"3.8.0"` | |
|
||||
| image.tag | string | `"3.9.3"` | |
|
||||
| imagePullSecrets | list | `[]` | |
|
||||
| ingress.enabled | bool | `false` | |
|
||||
| nameOverride | string | `""` | |
|
||||
|
|
|
@ -6,7 +6,7 @@ replicaCount: 1
|
|||
|
||||
image:
|
||||
repository: codercom/code-server
|
||||
tag: '3.8.0'
|
||||
tag: '3.9.3'
|
||||
pullPolicy: Always
|
||||
|
||||
imagePullSecrets: []
|
||||
|
|
|
@ -8,7 +8,7 @@ ENV PATH=/usr/local/node-$NODE_VERSION/bin:$PATH
|
|||
RUN npm install -g yarn
|
||||
|
||||
RUN yum groupinstall -y 'Development Tools'
|
||||
RUN yum install -y python2 libsecret-devel libX11-devel libxkbfile-devel
|
||||
RUN yum install -y python2
|
||||
|
||||
RUN npm config set python python2
|
||||
|
||||
|
@ -26,7 +26,6 @@ ENV PATH=/usr/local/go/bin:$GOPATH/bin:$PATH
|
|||
|
||||
# Install Go dependencies
|
||||
ENV GO111MODULE=on
|
||||
RUN go get mvdan.cc/sh/v3/cmd/shfmt
|
||||
RUN go get github.com/goreleaser/nfpm/cmd/nfpm@v1.9.0
|
||||
RUN go get github.com/goreleaser/nfpm/cmd/nfpm@v2.3.1
|
||||
|
||||
RUN curl -fsSL https://get.docker.com | sh
|
||||
|
|
|
@ -15,10 +15,7 @@ RUN curl -fsSL https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \
|
|||
apt-get update && apt-get install -y yarn
|
||||
|
||||
# Installs VS Code build deps.
|
||||
RUN apt-get install -y build-essential \
|
||||
libsecret-1-dev \
|
||||
libx11-dev \
|
||||
libxkbfile-dev
|
||||
RUN apt-get install -y build-essential
|
||||
|
||||
# Installs envsubst.
|
||||
RUN apt-get install -y gettext-base
|
||||
|
@ -40,10 +37,8 @@ ENV GOPATH=/gopath
|
|||
RUN mkdir -p $GOPATH && chmod -R 777 $GOPATH
|
||||
ENV PATH=/usr/local/go/bin:$GOPATH/bin:$PATH
|
||||
|
||||
# Install Go dependencies
|
||||
ENV GO111MODULE=on
|
||||
RUN go get mvdan.cc/sh/v3/cmd/shfmt
|
||||
RUN go get github.com/goreleaser/nfpm/cmd/nfpm@v1.9.0
|
||||
# More stable than go get
|
||||
RUN curl -sfL https://install.goreleaser.com/github.com/goreleaser/nfpm.sh | sh
|
||||
|
||||
RUN VERSION="$(curl -fsSL https://storage.googleapis.com/kubernetes-release/release/stable.txt)" && \
|
||||
curl -fsSL "https://storage.googleapis.com/kubernetes-release/release/$VERSION/bin/linux/amd64/kubectl" > /usr/local/bin/kubectl \
|
||||
|
|
23
ci/lib.sh
23
ci/lib.sh
|
@ -2,11 +2,11 @@
|
|||
set -euo pipefail
|
||||
|
||||
pushd() {
|
||||
builtin pushd "$@" > /dev/null
|
||||
builtin pushd "$@" >/dev/null
|
||||
}
|
||||
|
||||
popd() {
|
||||
builtin popd > /dev/null
|
||||
builtin popd >/dev/null
|
||||
}
|
||||
|
||||
pkg_json_version() {
|
||||
|
@ -57,7 +57,20 @@ curl() {
|
|||
# This will contain the artifacts we want.
|
||||
# https://developer.github.com/v3/actions/workflow-runs/#list-workflow-runs
|
||||
get_artifacts_url() {
|
||||
curl -fsSL 'https://api.github.com/repos/cdr/code-server/actions/workflows/ci.yaml/runs?status=success&event=push' | jq -r ".workflow_runs[] | select(.head_sha == \"$(git rev-parse HEAD)\") | .artifacts_url" | head -n 1
|
||||
local artifacts_url
|
||||
local workflow_runs_url="https://api.github.com/repos/cdr/code-server/actions/workflows/ci.yaml/runs?status=success&event=pull_request"
|
||||
# For releases, we look for run based on the branch name v$code_server_version
|
||||
# example: v3.9.3
|
||||
local version_branch="v$VERSION"
|
||||
artifacts_url=$(curl -fsSL "$workflow_runs_url" | jq -r ".workflow_runs[] | select(.head_branch == \"$version_branch\") | .artifacts_url" | head -n 1)
|
||||
if [[ -z "$artifacts_url" ]]; then
|
||||
echo >&2 "ERROR: artifacts_url came back empty"
|
||||
echo >&2 "We looked for a successful run triggered by a pull_request with for code-server version: $code_server_version and a branch named $version_branch"
|
||||
echo >&2 "URL used for curl call: $workflow_runs_url"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "$artifacts_url"
|
||||
}
|
||||
|
||||
# Grabs the artifact's download url.
|
||||
|
@ -75,7 +88,7 @@ download_artifact() {
|
|||
local tmp_file
|
||||
tmp_file="$(mktemp)"
|
||||
|
||||
curl -fsSL "$(get_artifact_url "$artifact_name")" > "$tmp_file"
|
||||
curl -fsSL "$(get_artifact_url "$artifact_name")" >"$tmp_file"
|
||||
unzip -q -o "$tmp_file" -d "$dst"
|
||||
rm "$tmp_file"
|
||||
}
|
||||
|
@ -103,7 +116,7 @@ RELEASE_PATH="${RELEASE_PATH-release}"
|
|||
# Code itself but also extensions will look specifically in this directory for
|
||||
# files (like the ripgrep binary or the oniguruma wasm).
|
||||
symlink_asar() {
|
||||
if [ ! -e node_modules.asar ]; then
|
||||
if [ ! -L node_modules.asar ]; then
|
||||
if [ "${WINDIR-}" ]; then
|
||||
# mklink takes the link name first.
|
||||
mklink /J node_modules.asar node_modules
|
||||
|
|
|
@ -4,6 +4,7 @@ RUN apt-get update \
|
|||
&& apt-get install -y \
|
||||
curl \
|
||||
dumb-init \
|
||||
zsh \
|
||||
htop \
|
||||
locales \
|
||||
man \
|
||||
|
@ -25,7 +26,7 @@ RUN adduser --gecos '' --disabled-password coder && \
|
|||
echo "coder ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers.d/nopasswd
|
||||
|
||||
RUN ARCH="$(dpkg --print-architecture)" && \
|
||||
curl -fsSL "https://github.com/boxboat/fixuid/releases/download/v0.4.1/fixuid-0.4.1-linux-$ARCH.tar.gz" | tar -C /usr/local/bin -xzf - && \
|
||||
curl -fsSL "https://github.com/boxboat/fixuid/releases/download/v0.5/fixuid-0.5-linux-$ARCH.tar.gz" | tar -C /usr/local/bin -xzf - && \
|
||||
chown root:root /usr/local/bin/fixuid && \
|
||||
chmod 4755 /usr/local/bin/fixuid && \
|
||||
mkdir -p /etc/fixuid && \
|
||||
|
|
|
@ -6,7 +6,7 @@ set -eu
|
|||
eval "$(fixuid -q)"
|
||||
|
||||
if [ "${DOCKER_USER-}" ] && [ "$DOCKER_USER" != "$USER" ]; then
|
||||
echo "$DOCKER_USER ALL=(ALL) NOPASSWD:ALL" | sudo tee -a /etc/sudoers.d/nopasswd > /dev/null
|
||||
echo "$DOCKER_USER ALL=(ALL) NOPASSWD:ALL" | sudo tee -a /etc/sudoers.d/nopasswd >/dev/null
|
||||
# Unfortunately we cannot change $HOME as we cannot move any bind mounts
|
||||
# nor can we bind mount $HOME into a new home as that requires a privileged container.
|
||||
sudo usermod --login "$DOCKER_USER" coder
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
# Only sourcing this so we get access to $VERSION
|
||||
source ./ci/lib.sh
|
||||
# Find the docs for bump-formula-pr here
|
||||
# https://github.com/Homebrew/brew/blob/master/Library/Homebrew/dev-cmd/bump-formula-pr.rb#L18
|
||||
brew bump-formula-pr --force --version="${VERSION}" code-server --no-browse --no-audit
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -8,7 +8,7 @@ main() {
|
|||
./ci/release-image/build.sh
|
||||
|
||||
mkdir -p release-images
|
||||
docker save "codercom/code-server-$ARCH:$VERSION" > "release-images/code-server-$ARCH-$VERSION.tar"
|
||||
docker save "codercom/code-server-$ARCH:$VERSION" >"release-images/code-server-$ARCH-$VERSION.tar"
|
||||
}
|
||||
|
||||
main "$@"
|
||||
|
|
|
@ -1,12 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
|
||||
yarn --frozen-lockfile
|
||||
|
||||
yarn fmt
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -1,12 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
|
||||
yarn --frozen-lockfile
|
||||
|
||||
yarn lint
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -6,7 +6,7 @@ main() {
|
|||
source ./ci/lib.sh
|
||||
|
||||
if [[ ${CI-} ]]; then
|
||||
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc
|
||||
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" >~/.npmrc
|
||||
fi
|
||||
|
||||
download_artifact npm-package ./release-npm-package
|
||||
|
|
|
@ -1,26 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
|
||||
NODE_VERSION=v12.18.4
|
||||
NODE_OS="$(uname | tr '[:upper:]' '[:lower:]')"
|
||||
NODE_ARCH="$(uname -m | sed 's/86_64/64/; s/aarch64/arm64/')"
|
||||
if [ "$NODE_OS" = "freebsd" ]; then
|
||||
mkdir -p "$PWD/node-$NODE_VERSION-$NODE_OS-$NODE_ARCH/bin"
|
||||
cp "$(which node)" "$PWD/node-$NODE_VERSION-$NODE_OS-$NODE_ARCH/bin"
|
||||
else
|
||||
curl -L "https://nodejs.org/dist/$NODE_VERSION/node-$NODE_VERSION-$NODE_OS-$NODE_ARCH.tar.gz" | tar -xz
|
||||
fi
|
||||
PATH="$PWD/node-$NODE_VERSION-$NODE_OS-$NODE_ARCH/bin:$PATH"
|
||||
|
||||
# https://github.com/actions/upload-artifact/issues/38
|
||||
tar -xzf release-npm-package/package.tar.gz
|
||||
|
||||
yarn release:standalone
|
||||
yarn test:standalone-release
|
||||
yarn package
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -1,17 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
|
||||
yarn --frozen-lockfile
|
||||
yarn build
|
||||
yarn build:vscode
|
||||
yarn release
|
||||
|
||||
# https://github.com/actions/upload-artifact/issues/38
|
||||
mkdir -p release-npm-package
|
||||
tar -czf release-npm-package/package.tar.gz release
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -1,12 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
main() {
|
||||
cd "$(dirname "$0")/../.."
|
||||
|
||||
yarn --frozen-lockfile
|
||||
|
||||
yarn test
|
||||
}
|
||||
|
||||
main "$@"
|
|
@ -0,0 +1,79 @@
|
|||
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
|
||||
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
|
||||
|
||||
# Contributor Covenant Code of Conduct
|
||||
|
||||
## Our Pledge
|
||||
|
||||
In the interest of fostering an open and welcoming environment, we as
|
||||
contributors and maintainers pledge to making participation in our project and
|
||||
our community a harassment-free experience for everyone, regardless of age, body
|
||||
size, disability, ethnicity, sex characteristics, gender identity and expression,
|
||||
level of experience, education, socio-economic status, nationality, personal
|
||||
appearance, race, religion, or sexual identity and orientation.
|
||||
|
||||
## Our Standards
|
||||
|
||||
Examples of behavior that contributes to creating a positive environment
|
||||
include:
|
||||
|
||||
- Using welcoming and inclusive language
|
||||
- Being respectful of differing viewpoints and experiences
|
||||
- Gracefully accepting constructive criticism
|
||||
- Focusing on what is best for the community
|
||||
- Showing empathy towards other community members
|
||||
|
||||
Examples of unacceptable behavior by participants include:
|
||||
|
||||
- The use of sexualized language or imagery and unwelcome sexual attention or
|
||||
advances
|
||||
- Trolling, insulting/derogatory comments, and personal or political attacks
|
||||
- Public or private harassment
|
||||
- Publishing others' private information, such as a physical or electronic
|
||||
address, without explicit permission
|
||||
- Other conduct which could reasonably be considered inappropriate in a
|
||||
professional setting
|
||||
|
||||
## Our Responsibilities
|
||||
|
||||
Project maintainers are responsible for clarifying the standards of acceptable
|
||||
behavior and are expected to take appropriate and fair corrective action in
|
||||
response to any instances of unacceptable behavior.
|
||||
|
||||
Project maintainers have the right and responsibility to remove, edit, or
|
||||
reject comments, commits, code, wiki edits, issues, and other contributions
|
||||
that are not aligned to this Code of Conduct, or to ban temporarily or
|
||||
permanently any contributor for other behaviors that they deem inappropriate,
|
||||
threatening, offensive, or harmful.
|
||||
|
||||
## Scope
|
||||
|
||||
This Code of Conduct applies both within project spaces and in public spaces
|
||||
when an individual is representing the project or its community. Examples of
|
||||
representing a project or community include using an official project e-mail
|
||||
address, posting via an official social media account, or acting as an appointed
|
||||
representative at an online or offline event. Representation of a project may be
|
||||
further defined and clarified by project maintainers.
|
||||
|
||||
## Enforcement
|
||||
|
||||
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
||||
reported by contacting the project team at opensource@coder.com. All
|
||||
complaints will be reviewed and investigated and will result in a response that
|
||||
is deemed necessary and appropriate to the circumstances. The project team is
|
||||
obligated to maintain confidentiality with regard to the reporter of an incident.
|
||||
Further details of specific enforcement policies may be posted separately.
|
||||
|
||||
Project maintainers who do not follow or enforce the Code of Conduct in good
|
||||
faith may face temporary or permanent repercussions as determined by other
|
||||
members of the project's leadership.
|
||||
|
||||
## Attribution
|
||||
|
||||
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
|
||||
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
|
||||
|
||||
[homepage]: https://www.contributor-covenant.org
|
||||
|
||||
For answers to common questions about this code of conduct, see
|
||||
https://www.contributor-covenant.org/faq
|
|
@ -6,6 +6,7 @@
|
|||
- [Requirements](#requirements)
|
||||
- [Development Workflow](#development-workflow)
|
||||
- [Updating VS Code](#updating-vs-code)
|
||||
- [Notes about Changes](#notes-about-changes)
|
||||
- [Build](#build)
|
||||
- [Structure](#structure)
|
||||
- [Modifications to VS Code](#modifications-to-vs-code)
|
||||
|
@ -36,7 +37,7 @@ There are several differences, however. You must:
|
|||
- Have [yarn](https://classic.yarnpkg.com/en/) installed (which is used to install JS packages and run development scripts)
|
||||
- Have [nfpm](https://github.com/goreleaser/nfpm) (which is used to build `.deb` and `.rpm` packages and [jq](https://stedolan.github.io/jq/) (used to build code-server releases) installed
|
||||
|
||||
The [CI container](../ci/images/debian8/Dockerfile) is a useful reference for all
|
||||
The [CI container](../ci/images/debian10/Dockerfile) is a useful reference for all
|
||||
of the dependencies code-server uses.
|
||||
|
||||
## Development Workflow
|
||||
|
@ -58,14 +59,18 @@ To develop inside an isolated Docker container:
|
|||
|
||||
### Updating VS Code
|
||||
|
||||
If you need to update VS Code, you can update the subtree with one line. Here's an example using the version 1.52:
|
||||
To update VS Code, follow these steps:
|
||||
|
||||
```shell
|
||||
# Add vscode as a new remote if you haven't already and fetch
|
||||
git remote add -f vscode https://github.com/microsoft/vscode.git
|
||||
1. Run `yarn update:vscode`.
|
||||
2. Enter a version. Ex. 1.53
|
||||
3. This will open a draft PR for you.
|
||||
4. There will be merge conflicts. First commit them.
|
||||
1. We do this because if we don't, it will be impossible to review your PR.
|
||||
5. Once they're all fixed, test code-server locally and make sure it all works.
|
||||
|
||||
git subtree pull --prefix lib/vscode vscode release/1.52 --squash --message "Update VS Code to 1.52"
|
||||
```
|
||||
#### Notes about Changes
|
||||
|
||||
- watch out for updates to `lib/vscode/src/vs/code/browser/workbench/workbench.html`. You may need to make changes to `src/browser/pages/vscode.html`
|
||||
|
||||
## Build
|
||||
|
||||
|
@ -120,10 +125,10 @@ node ./release
|
|||
|
||||
The `code-server` script serves an HTTP API for login and starting a remote VS Code process.
|
||||
|
||||
The CLI code is in [./src/node](./src/node) and the HTTP routes are implemented in
|
||||
[./src/node/app](./src/node/app).
|
||||
The CLI code is in [src/node](../src/node) and the HTTP routes are implemented in
|
||||
[src/node/routes](../src/node/routes).
|
||||
|
||||
Most of the meaty parts are in the VS Code portion of the codebase under [./lib/vscode](./lib/vscode), which we described next.
|
||||
Most of the meaty parts are in the VS Code portion of the codebase under [lib/vscode](../lib/vscode), which we described next.
|
||||
|
||||
### Modifications to VS Code
|
||||
|
||||
|
@ -133,7 +138,7 @@ and exposed an API to the front-end for file access and all UI needs.
|
|||
|
||||
Over time, Microsoft added support to VS Code to run it on the web. They have made
|
||||
the front-end open source, but not the server. As such, code-server v2 (and later) uses
|
||||
the VS Code front-end and implements the server. We do this by using a git subtree to fork and modify VS Code. This code lives under [./lib/vscode](./lib/vscode).
|
||||
the VS Code front-end and implements the server. We do this by using a git subtree to fork and modify VS Code. This code lives under [lib/vscode](../lib/vscode).
|
||||
|
||||
Some noteworthy changes in our version of VS Code:
|
||||
|
||||
|
@ -144,7 +149,6 @@ Some noteworthy changes in our version of VS Code:
|
|||
- Sending client-side telemetry through the server
|
||||
- Allowing modification of the display language
|
||||
- Making it possible for us to load code on the client
|
||||
- Making extensions work in the browser
|
||||
- Making it possible to install extensions of any kind
|
||||
- Fixing issue with getting disconnected when your machine sleeps or hibernates
|
||||
- Adding connection type to web socket query parameters
|
|
@ -4,9 +4,12 @@
|
|||
|
||||
- [Questions?](#questions)
|
||||
- [iPad Status?](#ipad-status)
|
||||
- [Community Projects (awesome-code-server)](#community-projects-awesome-code-server)
|
||||
- [How can I reuse my VS Code configuration?](#how-can-i-reuse-my-vs-code-configuration)
|
||||
- [Differences compared to VS Code?](#differences-compared-to-vs-code)
|
||||
- [Installing an extension](#installing-an-extension)
|
||||
- [How can I request a missing extension?](#how-can-i-request-a-missing-extension)
|
||||
- [Installing an extension manually](#installing-an-extension-manually)
|
||||
- [How do I configure the marketplace URL?](#how-do-i-configure-the-marketplace-url)
|
||||
- [Where are extensions stored?](#where-are-extensions-stored)
|
||||
- [How is this different from VS Code Codespaces?](#how-is-this-different-from-vs-code-codespaces)
|
||||
|
@ -15,6 +18,8 @@
|
|||
- [How do I securely access web services?](#how-do-i-securely-access-web-services)
|
||||
- [Sub-paths](#sub-paths)
|
||||
- [Sub-domains](#sub-domains)
|
||||
- [Why does the code-server proxy strip `/proxy/<port>` from the request path?](#why-does-the-code-server-proxy-strip-proxyport-from-the-request-path)
|
||||
- [Proxying to Create React App](#proxying-to-create-react-app)
|
||||
- [Multi-tenancy](#multi-tenancy)
|
||||
- [Docker in code-server container?](#docker-in-code-server-container)
|
||||
- [How can I disable telemetry?](#how-can-i-disable-telemetry)
|
||||
|
@ -23,7 +28,6 @@
|
|||
- [Heartbeat File](#heartbeat-file)
|
||||
- [Healthz endpoint](#healthz-endpoint)
|
||||
- [How does the config file work?](#how-does-the-config-file-work)
|
||||
- [How do I customize the "Go Home" button?](#how-do-i-customize-the-go-home-button)
|
||||
- [Isn't an install script piped into sh insecure?](#isnt-an-install-script-piped-into-sh-insecure)
|
||||
- [How do I make my keyboard shortcuts work?](#how-do-i-make-my-keyboard-shortcuts-work)
|
||||
- [Differences compared to Theia?](#differences-compared-to-theia)
|
||||
|
@ -40,6 +44,10 @@ Please file all questions and support requests at https://github.com/cdr/code-se
|
|||
|
||||
Please see [./ipad.md](./ipad.md).
|
||||
|
||||
## Community Projects (awesome-code-server)
|
||||
|
||||
Visit the [awesome-code-server](https://github.com/cdr/awesome-code-server) repository to view community projects and guides with code-server! Feel free to add your own!
|
||||
|
||||
## How can I reuse my VS Code configuration?
|
||||
|
||||
The very popular [Settings Sync](https://marketplace.visualstudio.com/items?itemName=Shan.code-settings-sync) extension works.
|
||||
|
@ -76,15 +84,43 @@ These are the closed source extensions presently unavailable:
|
|||
|
||||
For more about the closed source parts of VS Code, see [vscodium/vscodium](https://github.com/VSCodium/vscodium#why-does-this-exist).
|
||||
|
||||
### Installing an extension
|
||||
|
||||
Extensions can be installed from the marketplace using the extensions sidebar in
|
||||
code-server or from the command line:
|
||||
|
||||
```shell
|
||||
code-server --install-extension <extension id>
|
||||
# example: code-server --install-extension wesbos.theme-cobalt2
|
||||
```
|
||||
|
||||
## How can I request a missing extension?
|
||||
|
||||
Please open a new issue and select the `Extension request` template.
|
||||
We are currently in the process of transitioning to [Open VSX](https://open-vsx.org/).
|
||||
Once https://github.com/eclipse/openvsx/issues/249
|
||||
is implemented, we can fully make this transition. Therefore, we are no longer
|
||||
accepting new requests for extension requests.
|
||||
|
||||
If an extension is not available or does not work, you can grab its VSIX from its Github releases or
|
||||
build it yourself. Then run the `Extensions: Install from VSIX` command in the Command Palette and
|
||||
point to the .vsix file.
|
||||
Instead, we suggest one of the following:
|
||||
|
||||
See below for installing an extension from the cli.
|
||||
- [Switch to Open VSX](#how-do-i-configure-the-marketplace-url) now
|
||||
- Download and [install the extension manually](#installing-an-extension-manually)
|
||||
|
||||
## Installing an extension manually
|
||||
|
||||
If an extension is not available from the marketplace or does not work, you can
|
||||
grab its VSIX from its GitHub releases or build it yourself.
|
||||
|
||||
Once you have downloaded the VSIX to the remote machine you can either:
|
||||
|
||||
- Run the `Extensions: Install from VSIX` command in the Command Palette.
|
||||
- Use `code-server --install-extension <path to vsix>`
|
||||
|
||||
You can also download extensions from the command line. For instance, downloading off OpenVSX can be done like this:
|
||||
|
||||
```shell
|
||||
SERVICE_URL=https://open-vsx.org/vscode/gallery ITEM_URL=https://open-vsx.org/vscode/item code-server --install-extension <extension id>
|
||||
```
|
||||
|
||||
## How do I configure the marketplace URL?
|
||||
|
||||
|
@ -105,6 +141,8 @@ discussion regarding the use of the Microsoft URLs in forks:
|
|||
|
||||
https://github.com/microsoft/vscode/issues/31168#issue-244533026
|
||||
|
||||
See also [VSCodium's docs](https://github.com/VSCodium/vscodium/blob/master/DOCS.md#extensions--marketplace).
|
||||
|
||||
These variables are most valuable to our enterprise customers for whom we have a self hosted marketplace product.
|
||||
|
||||
## Where are extensions stored?
|
||||
|
@ -164,13 +202,20 @@ Again, please follow [./guide.md](./guide.md) for our recommendations on setting
|
|||
|
||||
## Can I store my password hashed?
|
||||
|
||||
Yes you can! Use `hashed-password` instead of `password`. Generate the hash with:
|
||||
Yes you can! Set the value of `hashed-password` instead of `password`. Generate the hash with:
|
||||
|
||||
```
|
||||
echo "thisismypassword" | sha256sum | cut -d' ' -f1
|
||||
printf "thisismypassword" | sha256sum | cut -d' ' -f1
|
||||
```
|
||||
|
||||
Of course replace `"thisismypassword"` with your actual password.
|
||||
Of course replace `thisismypassword` with your actual password.
|
||||
|
||||
Example:
|
||||
|
||||
```yaml
|
||||
auth: password
|
||||
hashed-password: 1da9133ab9dbd11d2937ec8d312e1e2569857059e73cc72df92e670928983ab5 # You got this from the command above
|
||||
```
|
||||
|
||||
## How do I securely access web services?
|
||||
|
||||
|
@ -201,12 +246,51 @@ code-server --proxy-domain <domain>
|
|||
Now you can browse to `<port>.<domain>`. Note that this uses the host header so
|
||||
ensure your reverse proxy forwards that information if you are using one.
|
||||
|
||||
## Why does the code-server proxy strip `/proxy/<port>` from the request path?
|
||||
|
||||
HTTP servers should strive to use relative URLs to avoid needed to be coupled to the
|
||||
absolute path at which they are served. This means you must use trailing slashes on all
|
||||
paths with subpaths. See https://blog.cdivilly.com/2019/02/28/uri-trailing-slashes
|
||||
|
||||
This is really the "correct" way things work and why the striping of the base path is the
|
||||
default. If your application uses relative URLs and does not assume the absolute path at
|
||||
which it is being served, it will just work no matter what port you decide to serve it off
|
||||
or if you put it in behind code-server or any other proxy!
|
||||
|
||||
However many people prefer the cleaner aesthetic of no trailing slashes. This couples you
|
||||
to the base path as you cannot use relative redirects correctly anymore. See the above
|
||||
link.
|
||||
|
||||
For users who are ok with this tradeoff, use `/absproxy` instead and the path will be
|
||||
passed as is. e.g. `/absproxy/3000/my-app-path`
|
||||
|
||||
### Proxying to Create React App
|
||||
|
||||
You must use `/absproxy/<port>` with create-react-app.
|
||||
See [#2565](https://github.com/cdr/code-server/issues/2565) and
|
||||
[#2222](https://github.com/cdr/code-server/issues/2222). You will need to inform
|
||||
create-react-app of the path at which you are serving via `$PUBLIC_URL` and webpack
|
||||
via `$WDS_SOCKET_PATH`.
|
||||
|
||||
e.g.
|
||||
|
||||
```sh
|
||||
PUBLIC_URL=/absproxy/3000 \
|
||||
WDS_SOCKET_PATH=$PUBLIC_URL/sockjs-node \
|
||||
BROWSER=none yarn start
|
||||
```
|
||||
|
||||
Then visit `https://my-code-server-address.io/absproxy/3000` to see your app exposed through
|
||||
code-server!
|
||||
|
||||
Highly recommend using the subdomain approach instead to avoid this class of issue.
|
||||
|
||||
## Multi-tenancy
|
||||
|
||||
If you want to run multiple code-servers on shared infrastructure, we recommend using virtual
|
||||
machines with a VM per user. This will easily allow users to run a docker daemon. If you want
|
||||
to use kubernetes, you'll definitely want to use [kubevirt](https://kubevirt.io) to give each
|
||||
user a virtual machine instead of just a container.
|
||||
to use kubernetes, you'll definitely want to use [kubevirt](https://kubevirt.io) or [sysbox](https://github.com/nestybox/sysbox) to give each
|
||||
user a VM-like experience instead of just a container.
|
||||
|
||||
## Docker in code-server container?
|
||||
|
||||
|
@ -299,16 +383,6 @@ The `--config` flag or `$CODE_SERVER_CONFIG` can be used to change the config fi
|
|||
|
||||
The default location also respects `$XDG_CONFIG_HOME`.
|
||||
|
||||
## How do I customize the "Go Home" button?
|
||||
|
||||
You can pass a URL to the `--home` flag like this:
|
||||
|
||||
```
|
||||
code-server --home=https://my-website.com
|
||||
```
|
||||
|
||||
Or you can define it in the config file with `home`.
|
||||
|
||||
## Isn't an install script piped into sh insecure?
|
||||
|
||||
Please give
|
Before Width: | Height: | Size: 974 KiB After Width: | Height: | Size: 974 KiB |
|
@ -22,9 +22,9 @@ To reiterate, `code-server` lets you run VS Code on a remote server and then acc
|
|||
Further docs are at:
|
||||
|
||||
- [README](../README.md) for a general overview
|
||||
- [INSTALL](../doc/install.md) for installation
|
||||
- [INSTALL](../docs/install.md) for installation
|
||||
- [FAQ](./FAQ.md) for common questions.
|
||||
- [CONTRIBUTING](../doc/CONTRIBUTING.md) for development docs
|
||||
- [CONTRIBUTING](../docs/CONTRIBUTING.md) for development docs
|
||||
|
||||
We highly recommend reading the [FAQ](./FAQ.md) on the [Differences compared to VS Code](./FAQ.md#differences-compared-to-vs-code) before beginning.
|
||||
|
||||
|
@ -180,8 +180,9 @@ Assuming you have been following the guide, edit your instance and checkmark the
|
|||
3. Install caddy https://caddyserver.com/docs/download#debian-ubuntu-raspbian.
|
||||
|
||||
```bash
|
||||
echo "deb [trusted=yes] https://apt.fury.io/caddy/ /" \
|
||||
| sudo tee -a /etc/apt/sources.list.d/caddy-fury.list
|
||||
sudo apt install -y debian-keyring debian-archive-keyring apt-transport-https
|
||||
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/cfg/gpg/gpg.155B6D79CA56EA34.key' | sudo apt-key add -
|
||||
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/cfg/setup/config.deb.txt?distro=debian&version=any-version' | sudo tee -a /etc/apt/sources.list.d/caddy-stable.list
|
||||
sudo apt update
|
||||
sudo apt install caddy
|
||||
```
|
|
@ -9,11 +9,14 @@
|
|||
- [Debian, Ubuntu](#debian-ubuntu)
|
||||
- [Fedora, CentOS, RHEL, SUSE](#fedora-centos-rhel-suse)
|
||||
- [Arch Linux](#arch-linux)
|
||||
- [Termux](#termux)
|
||||
- [Known Search Issue](#known-search-issue)
|
||||
- [yarn, npm](#yarn-npm)
|
||||
- [macOS](#macos)
|
||||
- [Standalone Releases](#standalone-releases)
|
||||
- [Docker](#docker)
|
||||
- [helm](#helm)
|
||||
- [Cloud Providers](#cloud-providers)
|
||||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
|
@ -86,18 +89,24 @@ commands presented in the rest of this document.
|
|||
|
||||
## Debian, Ubuntu
|
||||
|
||||
NOTE: The standalone arm64 .deb does not support Ubuntu <16.04.
|
||||
Please upgrade or [build with yarn](#yarn-npm).
|
||||
|
||||
```bash
|
||||
curl -fOL https://github.com/cdr/code-server/releases/download/v3.8.0/code-server_3.8.0_amd64.deb
|
||||
sudo dpkg -i code-server_3.8.0_amd64.deb
|
||||
curl -fOL https://github.com/cdr/code-server/releases/download/v3.9.3/code-server_3.9.3_amd64.deb
|
||||
sudo dpkg -i code-server_3.9.3_amd64.deb
|
||||
sudo systemctl enable --now code-server@$USER
|
||||
# Now visit http://127.0.0.1:8080. Your password is in ~/.config/code-server/config.yaml
|
||||
```
|
||||
|
||||
## Fedora, CentOS, RHEL, SUSE
|
||||
|
||||
NOTE: The standalone arm64 .rpm does not support CentOS 7.
|
||||
Please upgrade or [build with yarn](#yarn-npm).
|
||||
|
||||
```bash
|
||||
curl -fOL https://github.com/cdr/code-server/releases/download/v3.8.0/code-server-3.8.0-amd64.rpm
|
||||
sudo rpm -i code-server-3.8.0-amd64.rpm
|
||||
curl -fOL https://github.com/cdr/code-server/releases/download/v3.9.3/code-server-3.9.3-amd64.rpm
|
||||
sudo rpm -i code-server-3.9.3-amd64.rpm
|
||||
sudo systemctl enable --now code-server@$USER
|
||||
# Now visit http://127.0.0.1:8080. Your password is in ~/.config/code-server/config.yaml
|
||||
```
|
||||
|
@ -120,12 +129,42 @@ sudo systemctl enable --now code-server@$USER
|
|||
# Now visit http://127.0.0.1:8080. Your password is in ~/.config/code-server/config.yaml
|
||||
```
|
||||
|
||||
## Termux
|
||||
|
||||
Termux is an Android terminal application and Linux environment, which can also run code-server from your phone.
|
||||
|
||||
1. Install Termux from the [Google Play Store](https://play.google.com/store/apps/details?id=com.termux&hl=en_US&gl=US)
|
||||
2. Make sure it's up-to-date by running `apt update && apt upgrade`
|
||||
3. Install required packages: `apt install build-essential python git nodejs yarn`
|
||||
4. Install code-server: `yarn global add code-server`
|
||||
5. Run code-server: `code-server` and navigate to localhost:8080 in your browser
|
||||
|
||||
To upgrade run: `yarn global upgrade code-server --latest`
|
||||
|
||||
### Known Search Issue
|
||||
|
||||
There is a known issue with search not working on Android because it's missing `bin/rg`. To fix:
|
||||
|
||||
1. Install `ripgrep` with `pkg`
|
||||
```sh
|
||||
pkg install ripgrep
|
||||
```
|
||||
2. Make a soft link using `ln -s`
|
||||
|
||||
```sh
|
||||
# run this command inside the code-server directory
|
||||
ln -s $PREFIX/bin/rg ./lib/vscode/node_modules/vscode-ripgrep/bin/rg
|
||||
```
|
||||
|
||||
For more context, see [comment](https://github.com/cdr/code-server/issues/1730#issuecomment-721515979).
|
||||
|
||||
## yarn, npm
|
||||
|
||||
We recommend installing with `yarn` or `npm` when:
|
||||
|
||||
1. You aren't on `amd64` or `arm64`.
|
||||
2. If you're on Linux with glibc < v2.17 or glibcxx < v3.4.18
|
||||
2. If you're on Linux with glibc < v2.17 or glibcxx < v3.4.18 on amd64, or glibc < v2.23 or glibcxx < v3.4.21 on arm64.
|
||||
3. You're running Alpine Linux, or are using a non-glibc libc. See [#1430](https://github.com/cdr/code-server/issues/1430#issuecomment-629883198)
|
||||
|
||||
**note:** Installing via `yarn` or `npm` builds native modules on install and so requires C dependencies.
|
||||
See [./npm.md](./npm.md) for installing these dependencies.
|
||||
|
@ -166,10 +205,10 @@ Here is an example script for installing and using a standalone `code-server` re
|
|||
|
||||
```bash
|
||||
mkdir -p ~/.local/lib ~/.local/bin
|
||||
curl -fL https://github.com/cdr/code-server/releases/download/v3.8.0/code-server-3.8.0-linux-amd64.tar.gz \
|
||||
curl -fL https://github.com/cdr/code-server/releases/download/v3.9.3/code-server-3.9.3-linux-amd64.tar.gz \
|
||||
| tar -C ~/.local/lib -xz
|
||||
mv ~/.local/lib/code-server-3.8.0-linux-amd64 ~/.local/lib/code-server-3.8.0
|
||||
ln -s ~/.local/lib/code-server-3.8.0/bin/code-server ~/.local/bin/code-server
|
||||
mv ~/.local/lib/code-server-3.9.3-linux-amd64 ~/.local/lib/code-server-3.9.3
|
||||
ln -s ~/.local/lib/code-server-3.9.3/bin/code-server ~/.local/bin/code-server
|
||||
PATH="~/.local/bin:$PATH"
|
||||
code-server
|
||||
# Now visit http://127.0.0.1:8080. Your password is in ~/.config/code-server/config.yaml
|
||||
|
@ -204,3 +243,9 @@ https://hub.docker.com/r/linuxserver/code-server
|
|||
## helm
|
||||
|
||||
See [the chart](../ci/helm-chart).
|
||||
|
||||
## Cloud Providers
|
||||
|
||||
We maintain one-click apps and install scripts for different cloud providers such as DigitalOcean, Railway, Heroku, Azure, etc. Check out the repository:
|
||||
|
||||
https://github.com/cdr/deploy-code-server
|
|
@ -3,9 +3,11 @@
|
|||
# iPad
|
||||
|
||||
- [Known Issues](#known-issues)
|
||||
- [How to install PWA](#how-to-install-pwa)
|
||||
- [How to access code-server with a self signed certificate on iPad?](#how-to-access-code-server-with-a-self-signed-certificate-on-ipad)
|
||||
- [Servediter iPad App](#servediter-ipad-app)
|
||||
- [Raspberry Pi USB-C Network](#raspberry-pi-usb-c-network)
|
||||
- [Ctrl C Workaround](#ctrl-c-workaround)
|
||||
- [Recommendations](#recommendations)
|
||||
- [By 2022 iPad coding more desirable on Arm Macs](#by-2022-ipad-coding-more-desirable-on-arm-macs)
|
||||
|
||||
|
@ -27,6 +29,34 @@
|
|||
- Alternative: Install line-jump extension and use keyboard to nav by jumping large amount of lines
|
||||
- Alternative: Just use touch scrolling
|
||||
- See [issues tagged with the iPad label](https://github.com/cdr/code-server/issues?q=is%3Aopen+is%3Aissue+label%3AiPad) for more.
|
||||
- `ctrl+c` does not stop a long-running process in the browser
|
||||
- Tracking upstream issue here: [#114009](https://github.com/microsoft/vscode/issues/114009)
|
||||
- See [workaround](#ctrl-c-workaround)
|
||||
|
||||
## How to install PWA
|
||||
|
||||
To install the code-server PWA, follow these steps:
|
||||
|
||||
1. Open code-server in Safari
|
||||
2. Click the Share icon
|
||||
3. Click "Add to Home Screen"
|
||||
|
||||
Now when you open code-server from the home screen, you will be using the PWA.
|
||||
The advantages of this are more screen real estate and access to top-level keyboard shortcuts because it's running like an app.
|
||||
An example shortcut is the `cmd+w` to close an active file in the workbench. You can add this to your `keybindings.json` by doing the following:
|
||||
|
||||
1. Open up code-serer
|
||||
2. `Command Palette > Open Keyboard Shortcuts (JSON)`
|
||||
3. Add the following to your `keybindings.json`
|
||||
|
||||
```json
|
||||
{
|
||||
"key": "cmd+w",
|
||||
"command": "workbench.action.closeActiveEditor"
|
||||
}
|
||||
```
|
||||
|
||||
Test out command by hitting `cmd+w` to close an active file
|
||||
|
||||
## How to access code-server with a self signed certificate on iPad?
|
||||
|
||||
|
@ -91,6 +121,27 @@ Resources worthy of review:
|
|||
>
|
||||
> -- <cite>[Acker Apple](http://github.com/ackerapple/)</cite>
|
||||
|
||||
## Ctrl C Workaround
|
||||
|
||||
There is currently an issue with `ctrl+c` not stopping a running process in the integrated terminal. We have filed an issue upstream and are tracking [here](https://github.com/microsoft/vscode/issues/114009). As a temporary workaround, it works if you manually define the shortcut like so:
|
||||
|
||||
1. Open Command Palette
|
||||
2. Look for "Preferences: Open Keyboard Shortcuts (JSON)"
|
||||
3. Add this:
|
||||
|
||||
```json
|
||||
{
|
||||
"key": "ctrl+c",
|
||||
"command": "workbench.action.terminal.sendSequence",
|
||||
"args": {
|
||||
"text": "\u0003"
|
||||
},
|
||||
"when": "terminalFocus"
|
||||
}
|
||||
```
|
||||
|
||||
Source: [StackOverflow](https://stackoverflow.com/a/52735954/3015595)
|
||||
|
||||
## Recommendations
|
||||
|
||||
Once you have code-server accessible to your iPad a few things could help save you time:
|
|
@ -10,10 +10,15 @@
|
|||
|
||||
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
|
||||
|
||||
If you're installing the npm module you'll need certain dependencies to build
|
||||
the native modules used by VS Code.
|
||||
If you're installing the npm module you'll need certain dependencies to build the native modules used by VS Code.
|
||||
|
||||
You also need at least node v12 installed. See [#1633](https://github.com/cdr/code-server/issues/1633).
|
||||
- Node.js: version `>= 12`, `<= 14`
|
||||
|
||||
_Note: the Node.js version requirements are based on the VS Code Node.js requirements. See [here](https://github.com/microsoft/vscode/wiki/How-to-Contribute#prerequisites)._
|
||||
|
||||
Related:
|
||||
|
||||
- [#1633](https://github.com/cdr/code-server/issues/1633)
|
||||
|
||||
## Ubuntu, Debian
|
||||
|
||||
|
@ -21,9 +26,6 @@ You also need at least node v12 installed. See [#1633](https://github.com/cdr/co
|
|||
sudo apt-get install -y \
|
||||
build-essential \
|
||||
pkg-config \
|
||||
libx11-dev \
|
||||
libxkbfile-dev \
|
||||
libsecret-1-dev \
|
||||
python3
|
||||
npm config set python python3
|
||||
```
|
||||
|
@ -33,14 +35,14 @@ npm config set python python3
|
|||
```bash
|
||||
sudo yum groupinstall -y 'Development Tools'
|
||||
sudo yum config-manager --set-enabled PowerTools # unnecessary on CentOS 7
|
||||
sudo yum install -y python2 libsecret-devel libX11-devel libxkbfile-devel
|
||||
sudo yum install -y python2
|
||||
npm config set python python2
|
||||
```
|
||||
|
||||
## Alpine
|
||||
|
||||
```bash
|
||||
apk add alpine-sdk bash libstdc++ libc6-compat libx11-dev libxkbfile-dev libsecret-dev
|
||||
apk add alpine-sdk bash libstdc++ libc6-compat
|
||||
npm config set python python3
|
||||
```
|
||||
|
||||
|
@ -54,5 +56,5 @@ xcode-select --install
|
|||
|
||||
```sh
|
||||
pkg install -y git python npm-node12 yarn-node12 pkgconf
|
||||
pkg install -y libsecret libxkbfile libx11 libinotify
|
||||
pkg install -y libinotify
|
||||
```
|
24
install.sh
24
install.sh
|
@ -2,7 +2,7 @@
|
|||
set -eu
|
||||
|
||||
# code-server's automatic install script.
|
||||
# See https://github.com/cdr/code-server/blob/master/doc/install.md
|
||||
# See https://github.com/cdr/code-server/blob/main/docs/install.md
|
||||
|
||||
usage() {
|
||||
arg0="$0"
|
||||
|
@ -13,7 +13,7 @@ usage() {
|
|||
"
|
||||
fi
|
||||
|
||||
cath << EOF
|
||||
cath <<EOF
|
||||
Installs code-server for Linux, macOS and FreeBSD.
|
||||
It tries to use the system package manager if possible.
|
||||
After successful installation it explains how to start using code-server.
|
||||
|
@ -67,7 +67,7 @@ Usage:
|
|||
|
||||
It will cache all downloaded assets into ~/.cache/code-server
|
||||
|
||||
More installation docs are at https://github.com/cdr/code-server/blob/master/doc/install.md
|
||||
More installation docs are at https://github.com/cdr/code-server/blob/main/docs/install.md
|
||||
EOF
|
||||
}
|
||||
|
||||
|
@ -81,7 +81,7 @@ echo_latest_version() {
|
|||
|
||||
echo_npm_postinstall() {
|
||||
echoh
|
||||
cath << EOF
|
||||
cath <<EOF
|
||||
The npm package has been installed successfully!
|
||||
Please extend your path to use code-server:
|
||||
PATH="$NPM_BIN_DIR:\$PATH"
|
||||
|
@ -92,7 +92,7 @@ EOF
|
|||
|
||||
echo_standalone_postinstall() {
|
||||
echoh
|
||||
cath << EOF
|
||||
cath <<EOF
|
||||
Standalone release has been installed into $STANDALONE_INSTALL_PREFIX/lib/code-server-$VERSION
|
||||
Please extend your path to use code-server:
|
||||
PATH="$STANDALONE_INSTALL_PREFIX/bin:\$PATH"
|
||||
|
@ -103,7 +103,7 @@ EOF
|
|||
|
||||
echo_systemd_postinstall() {
|
||||
echoh
|
||||
cath << EOF
|
||||
cath <<EOF
|
||||
To have systemd start code-server now and restart on boot:
|
||||
sudo systemctl enable --now code-server@\$USER
|
||||
Or, if you don't want/need a background service you can run:
|
||||
|
@ -419,7 +419,7 @@ install_npm() {
|
|||
echoh
|
||||
echoerr "Please install npm or yarn to install code-server!"
|
||||
echoerr "You will need at least node v12 and a few C dependencies."
|
||||
echoerr "See the docs https://github.com/cdr/code-server#yarn-npm"
|
||||
echoerr "See the docs https://github.com/cdr/code-server/blob/v3.9.3/docs/install.md#yarn-npm"
|
||||
exit 1
|
||||
}
|
||||
|
||||
|
@ -509,7 +509,7 @@ arch() {
|
|||
}
|
||||
|
||||
command_exists() {
|
||||
command -v "$@" > /dev/null
|
||||
command -v "$@" >/dev/null
|
||||
}
|
||||
|
||||
sh_c() {
|
||||
|
@ -525,7 +525,7 @@ sudo_sh_c() {
|
|||
elif command_exists sudo; then
|
||||
sh_c "sudo $*"
|
||||
elif command_exists su; then
|
||||
sh_c "su -c '$*'"
|
||||
sh_c "su - -c '$*'"
|
||||
else
|
||||
echoh
|
||||
echoerr "This script needs to run the following command as root."
|
||||
|
@ -557,8 +557,8 @@ echoerr() {
|
|||
echoh "$@" >&2
|
||||
}
|
||||
|
||||
# humanpath replaces all occurances of " $HOME" with " ~"
|
||||
# and all occurances of '"$HOME' with the literal '"$HOME'.
|
||||
# humanpath replaces all occurrences of " $HOME" with " ~"
|
||||
# and all occurrences of '"$HOME' with the literal '"$HOME'.
|
||||
humanpath() {
|
||||
sed "s# $HOME# ~#g; s#\"$HOME#\"\$HOME#g"
|
||||
}
|
||||
|
@ -571,7 +571,7 @@ prefix() {
|
|||
fifo="$(mktemp -d)/fifo"
|
||||
mkfifo "$fifo"
|
||||
sed -e "s#^#$PREFIX: #" "$fifo" &
|
||||
"$@" > "$fifo" 2>&1
|
||||
"$@" >"$fifo" 2>&1
|
||||
}
|
||||
|
||||
main "$@"
|
||||
|
|
|
@ -8,7 +8,7 @@ set -e
|
|||
|
||||
SCRIPT_PATH="$(cd "$(dirname $0)" && pwd)"
|
||||
CONTAINER_IMAGE_REPOSITORY="$1"
|
||||
BRANCH="${2:-"master"}"
|
||||
BRANCH="${2:-"main"}"
|
||||
|
||||
if [ "${CONTAINER_IMAGE_REPOSITORY}" = "" ]; then
|
||||
echo "Container repository not specified!"
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
"name": "Code - OSS",
|
||||
|
||||
// Image contents: https://github.com/microsoft/vscode-dev-containers/blob/master/repository-containers/images/github.com/microsoft/vscode/.devcontainer/base.Dockerfile
|
||||
"image": "mcr.microsoft.com/vscode/devcontainers/repos/microsoft/vscode:branch-master",
|
||||
"image": "mcr.microsoft.com/vscode/devcontainers/repos/microsoft/vscode:branch-main",
|
||||
|
||||
"workspaceMount": "source=${localWorkspaceFolder},target=/home/node/workspace/vscode,type=bind,consistency=cached",
|
||||
"workspaceFolder": "/home/node/workspace/vscode",
|
||||
|
|
|
@ -13,6 +13,9 @@
|
|||
**/extensions/**/out/**
|
||||
**/extensions/**/build/**
|
||||
**/extensions/markdown-language-features/media/**
|
||||
**/extensions/markdown-language-features/notebook-out/**
|
||||
**/extensions/typescript-basics/test/colorize-fixtures/**
|
||||
# This is a code-server code symlink.
|
||||
**/extensions/**/dist/**
|
||||
# These are code-server code symlinks.
|
||||
src/vs/base/node/proxy_agent.ts
|
||||
src/vs/ipc.d.ts
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -4,11 +4,11 @@ about: Create a report to help us improve
|
|||
---
|
||||
<!-- ⚠️⚠️ Do Not Delete This! bug_report_template ⚠️⚠️ -->
|
||||
<!-- Please read our Rules of Conduct: https://opensource.microsoft.com/codeofconduct/ -->
|
||||
<!-- Please search existing issues to avoid creating duplicates. -->
|
||||
<!-- Also please test using the latest insiders build to make sure your issue has not already been fixed: https://code.visualstudio.com/insiders/ -->
|
||||
|
||||
<!-- Use Help > Report Issue to prefill these. -->
|
||||
- VSCode Version:
|
||||
<!-- 🕮 Read our guide about submitting issues: https://github.com/microsoft/vscode/wiki/Submitting-Bugs-and-Suggestions -->
|
||||
<!-- 🔎 Search existing issues to avoid creating duplicates. -->
|
||||
<!-- 🧪 Test using the latest Insiders build to see if your issue has already been fixed: https://code.visualstudio.com/insiders/ -->
|
||||
<!-- 💡 Instead of creating your report here, use 'Report Issue' from the 'Help' menu in VS Code to pre-fill useful information. -->
|
||||
- VS Code Version:
|
||||
- OS Version:
|
||||
|
||||
Steps to Reproduce:
|
||||
|
@ -16,5 +16,8 @@ Steps to Reproduce:
|
|||
1.
|
||||
2.
|
||||
|
||||
<!-- Launch with `code --disable-extensions` to check. -->
|
||||
<!-- 🔧 Launch with `code --disable-extensions` to check. -->
|
||||
Does this issue occur when all extensions are disabled?: Yes/No
|
||||
|
||||
<!-- 🪓 If you answered No above, use 'Help: Start Extension Bisect' from Command Palette to try to identify the cause. -->
|
||||
<!-- 📣 Issues caused by an extension need to be reported direct to the extension publisher. The 'Help > Report Issue' dialog can assist with this. -->
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
blank_issues_enabled: false
|
||||
contact_links:
|
||||
- name: Question
|
||||
url: https://stackoverflow.com/questions/tagged/visual-studio-code
|
||||
url: https://stackoverflow.com/questions/tagged/visual-studio-code
|
||||
about: Please ask and answer questions here.
|
||||
|
|
|
@ -1,37 +1,37 @@
|
|||
{
|
||||
'2018-01-29 18:00, US/Pacific': 'endgame',
|
||||
'2018-02-07 12:00, US/Pacific': 'release', # 1.20.0
|
||||
'2018-02-12 12:00, US/Pacific': 'development',
|
||||
'2018-02-14 16:00, Europe/Zurich': 'release', # 1.20.1
|
||||
'2018-02-19 16:00, Europe/Zurich': 'development',
|
||||
'2018-02-26 18:00, US/Pacific': 'endgame',
|
||||
'2018-03-07 12:00, US/Pacific': 'release', # 1.21.0
|
||||
'2018-03-12 12:00, US/Pacific': 'development',
|
||||
'2018-03-15 12:00, US/Pacific': 'release', # 1.21.1
|
||||
'2018-03-20 12:00, US/Pacific': 'development',
|
||||
'2018-03-26 18:00, US/Pacific': 'endgame',
|
||||
'2018-04-06 18:00, US/Pacific': 'release', # 1.22.1
|
||||
'2018-04-11 18:00, US/Pacific': 'development',
|
||||
'2018-04-12 12:00, US/Pacific': 'release', # 1.22.2
|
||||
'2018-04-17 12:00, US/Pacific': 'development',
|
||||
'2018-04-23 18:00, US/Pacific': 'endgame',
|
||||
'2018-05-03 12:00, US/Pacific': 'release', # 1.23.0
|
||||
'2018-05-08 12:00, US/Pacific': 'development',
|
||||
'2018-05-10 12:00, US/Pacific': 'release', # 1.23.1
|
||||
'2018-05-15 12:00, US/Pacific': 'development',
|
||||
'2018-05-28 18:00, US/Pacific': 'endgame',
|
||||
"2018-01-29 18:00, US/Pacific": "endgame",
|
||||
"2018-02-07 12:00, US/Pacific": "release", # 1.20.0
|
||||
"2018-02-12 12:00, US/Pacific": "development",
|
||||
"2018-02-14 16:00, Europe/Zurich": "release", # 1.20.1
|
||||
"2018-02-19 16:00, Europe/Zurich": "development",
|
||||
"2018-02-26 18:00, US/Pacific": "endgame",
|
||||
"2018-03-07 12:00, US/Pacific": "release", # 1.21.0
|
||||
"2018-03-12 12:00, US/Pacific": "development",
|
||||
"2018-03-15 12:00, US/Pacific": "release", # 1.21.1
|
||||
"2018-03-20 12:00, US/Pacific": "development",
|
||||
"2018-03-26 18:00, US/Pacific": "endgame",
|
||||
"2018-04-06 18:00, US/Pacific": "release", # 1.22.1
|
||||
"2018-04-11 18:00, US/Pacific": "development",
|
||||
"2018-04-12 12:00, US/Pacific": "release", # 1.22.2
|
||||
"2018-04-17 12:00, US/Pacific": "development",
|
||||
"2018-04-23 18:00, US/Pacific": "endgame",
|
||||
"2018-05-03 12:00, US/Pacific": "release", # 1.23.0
|
||||
"2018-05-08 12:00, US/Pacific": "development",
|
||||
"2018-05-10 12:00, US/Pacific": "release", # 1.23.1
|
||||
"2018-05-15 12:00, US/Pacific": "development",
|
||||
"2018-05-28 18:00, US/Pacific": "endgame",
|
||||
# 'release' not needed anymore, return to 'development' after releasing.
|
||||
'2018-06-06 12:00, US/Pacific': 'development', # 1.24.0 released
|
||||
'2018-06-25 18:00, US/Pacific': 'endgame',
|
||||
'2018-07-05 12:00, US/Pacific': 'development', # 1.25.0 released
|
||||
'2018-07-30 18:00, US/Pacific': 'endgame',
|
||||
'2018-08-13 12:00, US/Pacific': 'development', # 1.26.0 released
|
||||
'2018-08-27 18:00, US/Pacific': 'endgame',
|
||||
'2018-09-05 12:00, US/Pacific': 'development', # 1.27.0 released
|
||||
'2018-09-24 18:00, US/Pacific': 'endgame',
|
||||
'2018-10-08 09:00, US/Pacific': 'development', # 1.28.0 released
|
||||
'2018-10-29 18:00, US/Pacific': 'endgame',
|
||||
'2018-11-12 11:00, US/Pacific': 'development', # 1.29.0 released
|
||||
'2018-12-03 18:00, US/Pacific': 'endgame',
|
||||
'2018-12-12 13:00, US/Pacific': 'development', # 1.30.0 released
|
||||
"2018-06-06 12:00, US/Pacific": "development", # 1.24.0 released
|
||||
"2018-06-25 18:00, US/Pacific": "endgame",
|
||||
"2018-07-05 12:00, US/Pacific": "development", # 1.25.0 released
|
||||
"2018-07-30 18:00, US/Pacific": "endgame",
|
||||
"2018-08-13 12:00, US/Pacific": "development", # 1.26.0 released
|
||||
"2018-08-27 18:00, US/Pacific": "endgame",
|
||||
"2018-09-05 12:00, US/Pacific": "development", # 1.27.0 released
|
||||
"2018-09-24 18:00, US/Pacific": "endgame",
|
||||
"2018-10-08 09:00, US/Pacific": "development", # 1.28.0 released
|
||||
"2018-10-29 18:00, US/Pacific": "endgame",
|
||||
"2018-11-12 11:00, US/Pacific": "development", # 1.29.0 released
|
||||
"2018-12-03 18:00, US/Pacific": "endgame",
|
||||
"2018-12-12 13:00, US/Pacific": "development", # 1.30.0 released
|
||||
}
|
||||
|
|
|
@ -57,7 +57,7 @@
|
|||
"editor-theming": {"assign": []},
|
||||
"editor-wordnav": {"assign": ["alexdima"]},
|
||||
"editor-wrapping": {"assign": ["alexdima"]},
|
||||
"emmet": {"assign": []},
|
||||
"emmet": {"assign": ["rzhao271"]},
|
||||
"error-list": {"assign": ["sandy081"]},
|
||||
"explorer-custom": {"assign": ["sandy081"]},
|
||||
"extension-host": {"assign": []},
|
||||
|
@ -72,7 +72,7 @@
|
|||
"file-watcher": {"assign": ["bpasero"]},
|
||||
"font-rendering": {"assign": []},
|
||||
"formatting": {"assign": []},
|
||||
"git": {"assign": ["joaomoreno"]},
|
||||
"git": {"assign": ["eamodio"]},
|
||||
"gpu": {"assign": ["deepak1556"]},
|
||||
"grammar": {"assign": ["mjbvz"]},
|
||||
"grid-view": {"assign": ["joaomoreno"]},
|
||||
|
@ -81,9 +81,9 @@
|
|||
"icon-brand": {"assign": []},
|
||||
"icons-product": {"assign": ["misolori"]},
|
||||
"install-update": {"assign": []},
|
||||
"integrated-terminal": {"assign": ["Tyriar"]},
|
||||
"integrated-terminal-conpty": {"assign": ["Tyriar"]},
|
||||
"integrated-terminal-links": {"assign": ["Tyriar"]},
|
||||
"integrated-terminal": {"assign": ["meganrogge"]},
|
||||
"integrated-terminal-conpty": {"assign": ["meganrogge"]},
|
||||
"integrated-terminal-links": {"assign": ["meganrogge"]},
|
||||
"integration-test": {"assign": []},
|
||||
"intellisense-config": {"assign": []},
|
||||
"ipc": {"assign": ["joaomoreno"]},
|
||||
|
@ -119,7 +119,7 @@
|
|||
"remote": {"assign": []},
|
||||
"remote-explorer": {"assign": ["alexr00"]},
|
||||
"rename": {"assign": ["jrieken"]},
|
||||
"scm": {"assign": ["joaomoreno"]},
|
||||
"scm": {"assign": ["eamodio"]},
|
||||
"screencast-mode": {"assign": ["lszomoru"]},
|
||||
"search": {"assign": ["roblourens"]},
|
||||
"search-editor": {"assign": ["JacksonKearl"]},
|
||||
|
@ -159,7 +159,7 @@
|
|||
"workbench-electron": {"assign": ["deepak1556"]},
|
||||
"workbench-feedback": {"assign": ["bpasero"]},
|
||||
"workbench-history": {"assign": ["bpasero"]},
|
||||
"workbench-hot-exit": {"assign": ["Tyriar"]},
|
||||
"workbench-hot-exit": {"assign": []},
|
||||
"workbench-launch": {"assign": []},
|
||||
"workbench-link": {"assign": []},
|
||||
"workbench-multiroot": {"assign": ["bpasero"]},
|
||||
|
@ -172,7 +172,7 @@
|
|||
"workbench-tabs": {"assign": ["bpasero"]},
|
||||
"workbench-touchbar": {"assign": ["bpasero"]},
|
||||
"workbench-views": {"assign": ["sbatten"]},
|
||||
"workbench-welcome": {"assign": ["chrmarti"]},
|
||||
"workbench-welcome": {"assign": ["JacksonKearl"]},
|
||||
"workbench-window": {"assign": ["bpasero"]},
|
||||
"workbench-zen": {"assign": ["isidorn"]},
|
||||
"workspace-edit": {"assign": ["jrieken"]},
|
||||
|
|
|
@ -81,7 +81,7 @@
|
|||
"type": "label",
|
||||
"name": "*duplicate",
|
||||
"action": "close",
|
||||
"comment": "Thanks for creating this issue! We figured it's covering the same as another one we already have. Thus, we closed this one as a duplicate. You can search for existing issues [here](https://aka.ms/vscodeissuesearch). See also our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines.\n\nHappy Coding!"
|
||||
"comment": "Thanks for creating this issue! We figured it's covering the same as another one we already have. Thus, we closed this one as a duplicate. You can search for existing issues [here](${duplicateQuery}). See also our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines.\n\nHappy Coding!"
|
||||
},
|
||||
{
|
||||
"type": "comment",
|
||||
|
@ -93,7 +93,7 @@
|
|||
"addLabel": "z-author-verified",
|
||||
"removeLabel": "author-verification-requested",
|
||||
"requireLabel": "author-verification-requested",
|
||||
"disallowLabel": "awaiting-insiders-release"
|
||||
"disallowLabel": "unreleased"
|
||||
},
|
||||
{
|
||||
"type": "comment",
|
||||
|
@ -202,6 +202,19 @@
|
|||
"addLabel": "*caused-by-extension",
|
||||
"comment": "It looks like this is caused by the Python extension. Please file it with the repository [here](https://github.com/microsoft/vscode-python). Make sure to check their issue reporting template and provide them relevant information such as the extension version you're using. See also our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines for more information.\n\nHappy Coding!"
|
||||
},
|
||||
{
|
||||
"type": "comment",
|
||||
"name": "extJupyter",
|
||||
"allowUsers": [
|
||||
"cleidigh",
|
||||
"usernamehw",
|
||||
"gjsjohnmurray",
|
||||
"IllusionMH"
|
||||
],
|
||||
"action": "close",
|
||||
"addLabel": "*caused-by-extension",
|
||||
"comment": "It looks like this is caused by the Jupyter extension. Please file it with the repository [here](https://github.com/microsoft/vscode-jupyter). Make sure to check their issue reporting template and provide them relevant information such as the extension version you're using. See also our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines for more information.\n\nHappy Coding!"
|
||||
},
|
||||
{
|
||||
"type": "comment",
|
||||
"name": "extC",
|
||||
|
|
|
@ -1,12 +1,13 @@
|
|||
{
|
||||
perform: true,
|
||||
commands: [
|
||||
{
|
||||
type: 'comment',
|
||||
name: 'findDuplicates',
|
||||
allowUsers: ['cleidigh', 'usernamehw', 'gjsjohnmurray', 'IllusionMH'],
|
||||
action: 'comment',
|
||||
comment: "Potential duplicates:\n${potentialDuplicates}"
|
||||
}
|
||||
]
|
||||
perform: true,
|
||||
commands:
|
||||
[
|
||||
{
|
||||
type: "comment",
|
||||
name: "findDuplicates",
|
||||
allowUsers: ["cleidigh", "usernamehw", "gjsjohnmurray", "IllusionMH"],
|
||||
action: "comment",
|
||||
comment: "Potential duplicates:\n${potentialDuplicates}",
|
||||
},
|
||||
],
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
insidersLabel: 'insiders',
|
||||
insidersColor: '006b75',
|
||||
action: 'add',
|
||||
perform: true
|
||||
insidersLabel: "insiders",
|
||||
insidersColor: "006b75",
|
||||
action: "add",
|
||||
perform: true,
|
||||
}
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
insidersLabel: 'insiders',
|
||||
insidersColor: '006b75',
|
||||
action: 'remove',
|
||||
perform: true
|
||||
insidersLabel: "insiders",
|
||||
insidersColor: "006b75",
|
||||
action: "remove",
|
||||
perform: true,
|
||||
}
|
|
@ -1,8 +1,8 @@
|
|||
<!-- Thank you for submitting a Pull Request. Please:
|
||||
* Read our Pull Request guidelines:
|
||||
https://github.com/microsoft/vscode/wiki/How-to-Contribute#pull-requests.
|
||||
https://github.com/microsoft/vscode/wiki/How-to-Contribute#pull-requests
|
||||
* Associate an issue with the Pull Request.
|
||||
* Ensure that the code is up-to-date with the `master` branch.
|
||||
* Ensure that the code is up-to-date with the `main` branch.
|
||||
* Include a description of the proposed changes and how to test them.
|
||||
-->
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
perform: true,
|
||||
whenCreatedByTeam: false,
|
||||
comment: "(Experimental duplicate detection)\nThanks for submitting this issue. Please also check if it is already covered by an existing one, like:\n${potentialDuplicates}"
|
||||
perform: true,
|
||||
whenCreatedByTeam: false,
|
||||
comment: "(Experimental duplicate detection)\nThanks for submitting this issue. Please also check if it is already covered by an existing one, like:\n${potentialDuplicates}",
|
||||
}
|
||||
|
|
|
@ -1,9 +1,5 @@
|
|||
name: Author Verified
|
||||
on:
|
||||
repository_dispatch:
|
||||
types: [trigger-author-verified]
|
||||
schedule:
|
||||
- cron: 20 14 * * * # 4:20pm Zurich
|
||||
issues:
|
||||
types: [closed]
|
||||
|
||||
|
@ -13,28 +9,22 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Actions
|
||||
if: github.event_name != 'issues' || contains(github.event.issue.labels.*.name, 'author-verification-requested')
|
||||
if: contains(github.event.issue.labels.*.name, 'author-verification-requested') && contains(github.event.issue.labels.*.name, 'insiders-released')
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
ref: v37
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
ref: stable
|
||||
path: ./actions
|
||||
- name: Install Actions
|
||||
if: github.event_name != 'issues' || contains(github.event.issue.labels.*.name, 'author-verification-requested')
|
||||
if: contains(github.event.issue.labels.*.name, 'author-verification-requested') && contains(github.event.issue.labels.*.name, 'insiders-released')
|
||||
run: npm install --production --prefix ./actions
|
||||
- name: Checkout Repo
|
||||
if: github.event_name != 'issues' || contains(github.event.issue.labels.*.name, 'author-verification-requested')
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
path: ./repo
|
||||
fetch-depth: 0
|
||||
- name: Run Author Verified
|
||||
if: github.event_name != 'issues' || contains(github.event.issue.labels.*.name, 'author-verification-requested')
|
||||
if: contains(github.event.issue.labels.*.name, 'author-verification-requested') && contains(github.event.issue.labels.*.name, 'insiders-released')
|
||||
uses: ./actions/author-verified
|
||||
with:
|
||||
appInsightsKey: ${{secrets.TRIAGE_ACTIONS_APP_INSIGHTS}}
|
||||
token: ${{secrets.VSCODE_ISSUE_TRIAGE_BOT_PAT}}
|
||||
requestVerificationComment: "This bug has been fixed in to the latest release of [VS Code Insiders](https://code.visualstudio.com/insiders/)!\n\n@${author}, you can help us out by commenting `/verified` if things are now working as expected.\n\nIf things still don't seem right, please ensure you're on version ${commit} of Insiders (today's or later - you can use `Help: About` in the command pallette to check), and leave a comment letting us know what isn't working as expected.\n\nHappy Coding!"
|
||||
pendingReleaseLabel: awaiting-insiders-release
|
||||
requestVerificationComment: "This bug has been fixed in the latest release of [VS Code Insiders](https://code.visualstudio.com/insiders/)!\n\n@${author}, you can help us out by commenting `/verified` if things are now working as expected.\n\nIf things still don't seem right, please ensure you're on version ${commit} of Insiders (today's or later - you can use `Help: About` in the command palette to check), and leave a comment letting us know what isn't working as expected.\n\nHappy Coding!"
|
||||
releasedLabel: insiders-released
|
||||
verifiedLabel: verified
|
||||
authorVerificationRequestedLabel: author-verification-requested
|
||||
|
|
|
@ -0,0 +1,35 @@
|
|||
name: "Build Chat"
|
||||
|
||||
on:
|
||||
workflow_run:
|
||||
workflows:
|
||||
- CI
|
||||
types:
|
||||
- completed
|
||||
branches:
|
||||
- main
|
||||
- release/*
|
||||
|
||||
jobs:
|
||||
main:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
path: ./actions
|
||||
- name: Install Actions
|
||||
run: npm install --production --prefix ./actions
|
||||
- name: Install Additional Dependencies
|
||||
# Pulls in a bunch of other packages that arent needed for the rest of the actions
|
||||
run: npm install @azure/storage-blob@12.1.1
|
||||
- name: Build Chat
|
||||
uses: ./actions/build-chat
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
slack_token: ${{ secrets.SLACK_TOKEN }}
|
||||
storage_connection_string: ${{ secrets.BUILD_CHAT_STORAGE_CONNECTION_STRING }}
|
||||
workflow_run_url: ${{ github.event.workflow_run.url }}
|
||||
notification_channel: build
|
||||
log_channel: bot-log
|
|
@ -3,142 +3,280 @@ name: CI
|
|||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
- main
|
||||
- release/*
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
- main
|
||||
- release/*
|
||||
|
||||
jobs:
|
||||
# linux:
|
||||
# runs-on: ubuntu-latest
|
||||
# env:
|
||||
# CHILD_CONCURRENCY: "1"
|
||||
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
# steps:
|
||||
# - uses: actions/checkout@v1
|
||||
# # TODO: rename azure-pipelines/linux/xvfb.init to github-actions
|
||||
# - run: |
|
||||
# sudo apt-get update
|
||||
# sudo apt-get install -y libxkbfile-dev pkg-config libsecret-1-dev libxss1 dbus xvfb libgtk-3-0 libgbm1
|
||||
# sudo cp build/azure-pipelines/linux/xvfb.init /etc/init.d/xvfb
|
||||
# sudo chmod +x /etc/init.d/xvfb
|
||||
# sudo update-rc.d xvfb defaults
|
||||
# sudo service xvfb start
|
||||
# name: Setup Build Environment
|
||||
# - uses: actions/setup-node@v1
|
||||
# with:
|
||||
# node-version: 10
|
||||
# # TODO: cache node modules
|
||||
# - run: yarn --frozen-lockfile
|
||||
# name: Install Dependencies
|
||||
# - run: yarn electron x64
|
||||
# name: Download Electron
|
||||
# - run: yarn gulp hygiene
|
||||
# name: Run Hygiene Checks
|
||||
# - run: yarn monaco-compile-check
|
||||
# name: Run Monaco Editor Checks
|
||||
# - run: yarn valid-layers-check
|
||||
# name: Run Valid Layers Checks
|
||||
# - run: yarn compile
|
||||
# name: Compile Sources
|
||||
# - run: yarn download-builtin-extensions
|
||||
# name: Download Built-in Extensions
|
||||
# - run: DISPLAY=:10 ./scripts/test.sh --tfs "Unit Tests"
|
||||
# name: Run Unit Tests (Electron)
|
||||
# - run: DISPLAY=:10 yarn test-browser --browser chromium
|
||||
# name: Run Unit Tests (Browser)
|
||||
# - run: DISPLAY=:10 ./scripts/test-integration.sh --tfs "Integration Tests"
|
||||
# name: Run Integration Tests (Electron)
|
||||
|
||||
# windows:
|
||||
# runs-on: windows-2016
|
||||
# env:
|
||||
# CHILD_CONCURRENCY: "1"
|
||||
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
# steps:
|
||||
# - uses: actions/checkout@v1
|
||||
# - uses: actions/setup-node@v1
|
||||
# with:
|
||||
# node-version: 10
|
||||
# - uses: actions/setup-python@v1
|
||||
# with:
|
||||
# python-version: '2.x'
|
||||
# - run: yarn --frozen-lockfile
|
||||
# name: Install Dependencies
|
||||
# - run: yarn electron
|
||||
# name: Download Electron
|
||||
# - run: yarn gulp hygiene
|
||||
# name: Run Hygiene Checks
|
||||
# - run: yarn monaco-compile-check
|
||||
# name: Run Monaco Editor Checks
|
||||
# - run: yarn valid-layers-check
|
||||
# name: Run Valid Layers Checks
|
||||
# - run: yarn compile
|
||||
# name: Compile Sources
|
||||
# - run: yarn download-builtin-extensions
|
||||
# name: Download Built-in Extensions
|
||||
# - run: .\scripts\test.bat --tfs "Unit Tests"
|
||||
# name: Run Unit Tests (Electron)
|
||||
# - run: yarn test-browser --browser chromium
|
||||
# name: Run Unit Tests (Browser)
|
||||
# - run: .\scripts\test-integration.bat --tfs "Integration Tests"
|
||||
# name: Run Integration Tests (Electron)
|
||||
|
||||
# darwin:
|
||||
# runs-on: macos-latest
|
||||
# env:
|
||||
# CHILD_CONCURRENCY: "1"
|
||||
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
# steps:
|
||||
# - uses: actions/checkout@v1
|
||||
# - uses: actions/setup-node@v1
|
||||
# with:
|
||||
# node-version: 10
|
||||
# - run: yarn --frozen-lockfile
|
||||
# name: Install Dependencies
|
||||
# - run: yarn electron x64
|
||||
# name: Download Electron
|
||||
# - run: yarn gulp hygiene
|
||||
# name: Run Hygiene Checks
|
||||
# - run: yarn monaco-compile-check
|
||||
# name: Run Monaco Editor Checks
|
||||
# - run: yarn valid-layers-check
|
||||
# name: Run Valid Layers Checks
|
||||
# - run: yarn compile
|
||||
# name: Compile Sources
|
||||
# - run: yarn download-builtin-extensions
|
||||
# name: Download Built-in Extensions
|
||||
# - run: ./scripts/test.sh --tfs "Unit Tests"
|
||||
# name: Run Unit Tests (Electron)
|
||||
# - run: yarn test-browser --browser chromium --browser webkit
|
||||
# name: Run Unit Tests (Browser)
|
||||
# - run: ./scripts/test-integration.sh --tfs "Integration Tests"
|
||||
# name: Run Integration Tests (Electron)
|
||||
|
||||
monaco:
|
||||
runs-on: ubuntu-latest
|
||||
windows:
|
||||
name: Windows
|
||||
runs-on: windows-latest
|
||||
timeout-minutes: 30
|
||||
env:
|
||||
CHILD_CONCURRENCY: "1"
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
# TODO: rename azure-pipelines/linux/xvfb.init to github-actions
|
||||
- run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y libxkbfile-dev pkg-config libsecret-1-dev libxss1 dbus xvfb libgtk-3-0 libgbm1
|
||||
sudo cp build/azure-pipelines/linux/xvfb.init /etc/init.d/xvfb
|
||||
sudo chmod +x /etc/init.d/xvfb
|
||||
sudo update-rc.d xvfb defaults
|
||||
sudo service xvfb start
|
||||
name: Setup Build Environment
|
||||
- uses: actions/setup-node@v1
|
||||
with:
|
||||
node-version: 10
|
||||
- run: yarn --frozen-lockfile
|
||||
name: Install Dependencies
|
||||
- run: yarn monaco-compile-check
|
||||
name: Run Monaco Editor Checks
|
||||
- run: yarn gulp editor-esm-bundle
|
||||
name: Editor Distro & ESM Bundle
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: 12
|
||||
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: "2.x"
|
||||
|
||||
- name: Compute node modules cache key
|
||||
id: nodeModulesCacheKey
|
||||
run: echo "::set-output name=value::$(node build/azure-pipelines/common/computeNodeModulesCacheKey.js)"
|
||||
- name: Cache node_modules archive
|
||||
id: cacheNodeModules
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: ".build/node_modules_cache"
|
||||
key: "${{ runner.os }}-cacheNodeModulesArchive-${{ steps.nodeModulesCacheKey.outputs.value }}"
|
||||
- name: Extract node_modules archive
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit == 'true' }}
|
||||
run: 7z.exe x .build/node_modules_cache/cache.7z -aos
|
||||
- name: Get yarn cache directory path
|
||||
id: yarnCacheDirPath
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
run: echo "::set-output name=dir::$(yarn cache dir)"
|
||||
- name: Cache yarn directory
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: ${{ steps.yarnCacheDirPath.outputs.dir }}
|
||||
key: ${{ runner.os }}-yarnCacheDir-${{ steps.nodeModulesCacheKey.outputs.value }}
|
||||
restore-keys: ${{ runner.os }}-yarnCacheDir-
|
||||
- name: Execute yarn
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
ELECTRON_SKIP_BINARY_DOWNLOAD: 1
|
||||
run: yarn --frozen-lockfile --network-timeout 180000
|
||||
- name: Create node_modules archive
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
run: |
|
||||
mkdir -Force .build
|
||||
node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt
|
||||
mkdir -Force .build/node_modules_cache
|
||||
7z.exe a .build/node_modules_cache/cache.7z -mx3 `@.build/node_modules_list.txt
|
||||
|
||||
- name: Compile and Download
|
||||
run: yarn npm-run-all --max_old_space_size=4095 -lp compile "electron x64" playwright-install download-builtin-extensions
|
||||
|
||||
- name: Run Unit Tests (Electron)
|
||||
run: .\scripts\test.bat
|
||||
|
||||
- name: Run Unit Tests (Browser)
|
||||
run: yarn test-browser --browser chromium
|
||||
|
||||
- name: Run Integration Tests (Electron)
|
||||
run: .\scripts\test-integration.bat
|
||||
|
||||
linux:
|
||||
name: Linux
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 30
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
# TODO: rename azure-pipelines/linux/xvfb.init to github-actions
|
||||
- name: Setup Build Environment
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y libxkbfile-dev pkg-config libsecret-1-dev libxss1 dbus xvfb libgtk-3-0 libgbm1
|
||||
sudo cp build/azure-pipelines/linux/xvfb.init /etc/init.d/xvfb
|
||||
sudo chmod +x /etc/init.d/xvfb
|
||||
sudo update-rc.d xvfb defaults
|
||||
sudo service xvfb start
|
||||
|
||||
- uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: 12
|
||||
|
||||
- name: Compute node modules cache key
|
||||
id: nodeModulesCacheKey
|
||||
run: echo "::set-output name=value::$(node build/azure-pipelines/common/computeNodeModulesCacheKey.js)"
|
||||
- name: Cache node modules
|
||||
id: cacheNodeModules
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: "**/node_modules"
|
||||
key: ${{ runner.os }}-cacheNodeModules11-${{ steps.nodeModulesCacheKey.outputs.value }}
|
||||
restore-keys: ${{ runner.os }}-cacheNodeModules11-
|
||||
- name: Get yarn cache directory path
|
||||
id: yarnCacheDirPath
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
run: echo "::set-output name=dir::$(yarn cache dir)"
|
||||
- name: Cache yarn directory
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: ${{ steps.yarnCacheDirPath.outputs.dir }}
|
||||
key: ${{ runner.os }}-yarnCacheDir-${{ steps.nodeModulesCacheKey.outputs.value }}
|
||||
restore-keys: ${{ runner.os }}-yarnCacheDir-
|
||||
- name: Execute yarn
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
ELECTRON_SKIP_BINARY_DOWNLOAD: 1
|
||||
run: yarn --frozen-lockfile --network-timeout 180000
|
||||
|
||||
- name: Compile and Download
|
||||
run: yarn npm-run-all --max_old_space_size=4095 -lp compile "electron x64" playwright-install download-builtin-extensions
|
||||
|
||||
- name: Run Unit Tests (Electron)
|
||||
id: electron-unit-tests
|
||||
run: DISPLAY=:10 ./scripts/test.sh
|
||||
|
||||
- name: Run Unit Tests (Browser)
|
||||
id: browser-unit-tests
|
||||
run: DISPLAY=:10 yarn test-browser --browser chromium
|
||||
|
||||
- name: Run Integration Tests (Electron)
|
||||
id: electron-integration-tests
|
||||
run: DISPLAY=:10 ./scripts/test-integration.sh
|
||||
|
||||
darwin:
|
||||
name: macOS
|
||||
runs-on: macos-latest
|
||||
timeout-minutes: 30
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: 12
|
||||
|
||||
- name: Compute node modules cache key
|
||||
id: nodeModulesCacheKey
|
||||
run: echo "::set-output name=value::$(node build/azure-pipelines/common/computeNodeModulesCacheKey.js)"
|
||||
- name: Cache node modules
|
||||
id: cacheNodeModules
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: "**/node_modules"
|
||||
key: ${{ runner.os }}-cacheNodeModules11-${{ steps.nodeModulesCacheKey.outputs.value }}
|
||||
restore-keys: ${{ runner.os }}-cacheNodeModules11-
|
||||
- name: Get yarn cache directory path
|
||||
id: yarnCacheDirPath
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
run: echo "::set-output name=dir::$(yarn cache dir)"
|
||||
- name: Cache yarn directory
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: ${{ steps.yarnCacheDirPath.outputs.dir }}
|
||||
key: ${{ runner.os }}-yarnCacheDir-${{ steps.nodeModulesCacheKey.outputs.value }}
|
||||
restore-keys: ${{ runner.os }}-yarnCacheDir-
|
||||
- name: Execute yarn
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
ELECTRON_SKIP_BINARY_DOWNLOAD: 1
|
||||
run: yarn --frozen-lockfile --network-timeout 180000
|
||||
|
||||
- name: Compile and Download
|
||||
run: yarn npm-run-all --max_old_space_size=4095 -lp compile "electron x64" playwright-install download-builtin-extensions
|
||||
|
||||
- name: Run Unit Tests (Electron)
|
||||
run: DISPLAY=:10 ./scripts/test.sh
|
||||
|
||||
- name: Run Unit Tests (Browser)
|
||||
run: DISPLAY=:10 yarn test-browser --browser chromium
|
||||
|
||||
- name: Run Integration Tests (Electron)
|
||||
run: DISPLAY=:10 ./scripts/test-integration.sh
|
||||
|
||||
hygiene:
|
||||
name: Hygiene, Layering and Monaco Editor
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 30
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: 12
|
||||
|
||||
- name: Compute node modules cache key
|
||||
id: nodeModulesCacheKey
|
||||
run: echo "::set-output name=value::$(node build/azure-pipelines/common/computeNodeModulesCacheKey.js)"
|
||||
- name: Cache node modules
|
||||
id: cacheNodeModules
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: "**/node_modules"
|
||||
key: ${{ runner.os }}-cacheNodeModules11-${{ steps.nodeModulesCacheKey.outputs.value }}
|
||||
restore-keys: ${{ runner.os }}-cacheNodeModules11-
|
||||
- name: Get yarn cache directory path
|
||||
id: yarnCacheDirPath
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
run: echo "::set-output name=dir::$(yarn cache dir)"
|
||||
- name: Cache yarn directory
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: ${{ steps.yarnCacheDirPath.outputs.dir }}
|
||||
key: ${{ runner.os }}-yarnCacheDir-${{ steps.nodeModulesCacheKey.outputs.value }}
|
||||
restore-keys: ${{ runner.os }}-yarnCacheDir-
|
||||
- name: Execute yarn
|
||||
if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }}
|
||||
env:
|
||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
||||
ELECTRON_SKIP_BINARY_DOWNLOAD: 1
|
||||
run: yarn --frozen-lockfile --network-timeout 180000
|
||||
|
||||
- name: Run Hygiene Checks
|
||||
run: yarn gulp hygiene
|
||||
|
||||
- name: Run Valid Layers Checks
|
||||
run: yarn valid-layers-check
|
||||
|
||||
- name: Run Monaco Editor Checks
|
||||
run: yarn monaco-compile-check
|
||||
|
||||
- name: Run Trusted Types Checks
|
||||
run: yarn tsec-compile-check
|
||||
|
||||
- name: Editor Distro & ESM Bundle
|
||||
run: yarn gulp editor-esm-bundle
|
||||
|
||||
- name: Typings validation prep
|
||||
run: |
|
||||
mkdir typings-test
|
||||
|
||||
- name: Typings validation
|
||||
working-directory: ./typings-test
|
||||
run: |
|
||||
yarn init -yp
|
||||
../node_modules/.bin/tsc --init
|
||||
echo "import '../out-monaco-editor-core';" > a.ts
|
||||
../node_modules/.bin/tsc --noEmit
|
||||
|
||||
- name: Webpack Editor
|
||||
working-directory: ./test/monaco
|
||||
run: yarn run bundle
|
||||
|
||||
- name: Compile Editor Tests
|
||||
working-directory: ./test/monaco
|
||||
run: yarn run compile
|
||||
|
||||
- name: Download Playwright
|
||||
run: yarn playwright-install
|
||||
|
||||
- name: Run Editor Tests
|
||||
timeout-minutes: 5
|
||||
working-directory: ./test/monaco
|
||||
run: yarn test
|
||||
|
|
|
@ -2,48 +2,47 @@ name: "Code Scanning"
|
|||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '0 0 * * 2'
|
||||
- cron: "0 0 * * 2"
|
||||
|
||||
jobs:
|
||||
CodeQL-Build:
|
||||
|
||||
# CodeQL runs on ubuntu-latest and windows-latest
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
# We must fetch at least the immediate parents so that if this is
|
||||
# a pull request then we can checkout the head.
|
||||
fetch-depth: 2
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
# We must fetch at least the immediate parents so that if this is
|
||||
# a pull request then we can checkout the head.
|
||||
fetch-depth: 2
|
||||
|
||||
# If this run was triggered by a pull request event, then checkout
|
||||
# the head of the pull request instead of the merge commit.
|
||||
- run: git checkout HEAD^2
|
||||
if: ${{ github.event_name == 'pull_request' }}
|
||||
# If this run was triggered by a pull request event, then checkout
|
||||
# the head of the pull request instead of the merge commit.
|
||||
- run: git checkout HEAD^2
|
||||
if: ${{ github.event_name == 'pull_request' }}
|
||||
|
||||
# Initializes the CodeQL tools for scanning.
|
||||
- name: Initialize CodeQL
|
||||
uses: github/codeql-action/init@v1
|
||||
with:
|
||||
languages: javascript
|
||||
# Initializes the CodeQL tools for scanning.
|
||||
- name: Initialize CodeQL
|
||||
uses: github/codeql-action/init@v1
|
||||
with:
|
||||
languages: javascript
|
||||
|
||||
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
||||
# If this step fails, then you should remove it and run the build manually (see below)
|
||||
- name: Autobuild
|
||||
uses: github/codeql-action/autobuild@v1
|
||||
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
||||
# If this step fails, then you should remove it and run the build manually (see below)
|
||||
- name: Autobuild
|
||||
uses: github/codeql-action/autobuild@v1
|
||||
|
||||
# ℹ️ Command-line programs to run using the OS shell.
|
||||
# 📚 https://git.io/JvXDl
|
||||
# ℹ️ Command-line programs to run using the OS shell.
|
||||
# 📚 https://git.io/JvXDl
|
||||
|
||||
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
|
||||
# and modify them (or add more) to build your code if your project
|
||||
# uses a compiled language
|
||||
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
|
||||
# and modify them (or add more) to build your code if your project
|
||||
# uses a compiled language
|
||||
|
||||
#- run: |
|
||||
# make bootstrap
|
||||
# make release
|
||||
#- run: |
|
||||
# make bootstrap
|
||||
# make release
|
||||
|
||||
- name: Perform CodeQL Analysis
|
||||
uses: github/codeql-action/analyze@v1
|
||||
- name: Perform CodeQL Analysis
|
||||
uses: github/codeql-action/analyze@v1
|
||||
|
|
|
@ -10,8 +10,8 @@ jobs:
|
|||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
ref: v37
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
ref: stable
|
||||
path: ./actions
|
||||
- name: Install Actions
|
||||
run: npm install --production --prefix ./actions
|
||||
|
|
|
@ -12,8 +12,8 @@ jobs:
|
|||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
ref: v37
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
ref: stable
|
||||
path: ./actions
|
||||
- name: Install Actions
|
||||
run: npm install --production --prefix ./actions
|
||||
|
@ -38,7 +38,7 @@ jobs:
|
|||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install --upgrade numpy scipy scikit-learn joblib nltk simpletransformers torch torchvision
|
||||
pip install --upgrade numpy==1.20.0 scipy==1.6.0 scikit-learn==0.24.1 joblib==1.0.0 nltk==3.5 simpletransformers==0.51.16 torch==1.7.1 torchvision==0.8.2
|
||||
- name: "Run Classifier: Generator"
|
||||
run: python ./actions/classifier-deep/apply/generate-labels/main.py
|
||||
- name: "Run Classifier: Labeler"
|
||||
|
|
|
@ -10,8 +10,8 @@ jobs:
|
|||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
ref: v37
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
ref: stable
|
||||
path: ./actions
|
||||
- name: Install Actions
|
||||
run: npm install --production --prefix ./actions
|
||||
|
|
|
@ -2,14 +2,14 @@ name: VS Code Repo Dev Container Cache Image Generation
|
|||
|
||||
on:
|
||||
push:
|
||||
# Currently doing this for master, but could be done for PRs as well
|
||||
# Currently doing this for main, but could be done for PRs as well
|
||||
branches:
|
||||
- 'master'
|
||||
- "main"
|
||||
|
||||
# Only updates to these files result in changes to installed packages, so skip otherwise
|
||||
paths:
|
||||
- '**/package-lock.json'
|
||||
- '**/yarn.lock'
|
||||
- "**/package-lock.json"
|
||||
- "**/yarn.lock"
|
||||
|
||||
jobs:
|
||||
devcontainer:
|
||||
|
@ -35,7 +35,6 @@ jobs:
|
|||
az acr login --name $ACR_REGISTRY_NAME
|
||||
|
||||
GIT_BRANCH=$(echo "${{ github.ref }}" | grep -oP 'refs/(heads|tags)/\K(.+)')
|
||||
if [ "$GIT_BRANCH" == "" ]; then GIT_BRANCH=master; fi
|
||||
if [ "$GIT_BRANCH" == "" ]; then GIT_BRANCH=main; fi
|
||||
|
||||
.devcontainer/cache/build-cache-image.sh "${{ secrets.CONTAINER_IMAGE_REGISTRY }}/public/vscode/devcontainers/repos/microsoft/vscode" "${GIT_BRANCH}"
|
||||
|
||||
|
|
|
@ -12,8 +12,8 @@ jobs:
|
|||
if: contains(github.event.issue.labels.*.name, '*english-please')
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
ref: v37
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
ref: stable
|
||||
path: ./actions
|
||||
- name: Install Actions
|
||||
if: contains(github.event.issue.labels.*.name, '*english-please')
|
||||
|
|
|
@ -16,9 +16,9 @@ jobs:
|
|||
if: github.event_name != 'issues' || contains(github.event.issue.labels.*.name, 'feature-request')
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
path: ./actions
|
||||
ref: v37
|
||||
ref: stable
|
||||
- name: Install Actions
|
||||
if: github.event_name != 'issues' || contains(github.event.issue.labels.*.name, 'feature-request')
|
||||
run: npm install --production --prefix ./actions
|
||||
|
|
|
@ -12,9 +12,9 @@ jobs:
|
|||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
path: ./actions
|
||||
ref: v37
|
||||
ref: stable
|
||||
- name: Install Actions
|
||||
run: npm install --production --prefix ./actions
|
||||
- name: Install Storage Module
|
||||
|
|
|
@ -12,9 +12,9 @@ jobs:
|
|||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
path: ./actions
|
||||
ref: v37
|
||||
ref: stable
|
||||
- name: Install Actions
|
||||
run: npm install --production --prefix ./actions
|
||||
- name: Run Locker
|
||||
|
@ -24,3 +24,5 @@ jobs:
|
|||
appInsightsKey: ${{secrets.TRIAGE_ACTIONS_APP_INSIGHTS}}
|
||||
daysSinceUpdate: 3
|
||||
ignoredLabel: "*out-of-scope"
|
||||
ignoreLabelUntil: "author-verification-requested"
|
||||
labelUntil: "verified"
|
||||
|
|
|
@ -12,9 +12,9 @@ jobs:
|
|||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
path: ./actions
|
||||
ref: v37
|
||||
ref: stable
|
||||
- name: Install Actions
|
||||
run: npm install --production --prefix ./actions
|
||||
- name: Run Needs More Info Closer
|
||||
|
@ -24,7 +24,7 @@ jobs:
|
|||
token: ${{secrets.VSCODE_ISSUE_TRIAGE_BOT_PAT}}
|
||||
label: needs more info
|
||||
closeDays: 7
|
||||
additionalTeam: "cleidigh|usernamehw|gjsjohnmurray|IllusionMH"
|
||||
additionalTeam: "cleidigh|usernamehw|gjsjohnmurray|IllusionMH"
|
||||
closeComment: "This issue has been closed automatically because it needs more information and has not had recent activity. See also our [issue reporting](https://aka.ms/vscodeissuereporting) guidelines.\n\nHappy Coding!"
|
||||
pingDays: 80
|
||||
pingComment: "Hey @${assignee}, this issue might need further attention.\n\n@${author}, you can help us out by closing this issue if the problem no longer exists, or adding more information."
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
name: Prevent yarn.lock changes in PRs
|
||||
on: [pull_request]
|
||||
|
||||
jobs:
|
||||
main:
|
||||
name: Prevent yarn.lock changes in PRs
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- id: file_changes
|
||||
uses: trilom/file-changes-action@v1.2.4
|
||||
- name: Check for yarn.lock changes
|
||||
run: |
|
||||
cat $HOME/files.json | jq -e '.[] | test("yarn\\.lock$") | not' \
|
||||
|| (echo "Changes to yarn.lock files aren't allowed in PRs." && exit 1)
|
|
@ -1,4 +1,4 @@
|
|||
name: Commands
|
||||
name: On Comment
|
||||
on:
|
||||
issue_comment:
|
||||
types: [created]
|
||||
|
@ -11,9 +11,9 @@ jobs:
|
|||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
path: ./actions
|
||||
ref: v37
|
||||
ref: stable
|
||||
- name: Install Actions
|
||||
run: npm install --production --prefix ./actions
|
||||
- name: Run Commands
|
||||
|
@ -22,3 +22,10 @@ jobs:
|
|||
appInsightsKey: ${{secrets.TRIAGE_ACTIONS_APP_INSIGHTS}}
|
||||
token: ${{secrets.VSCODE_ISSUE_TRIAGE_BOT_PAT}}
|
||||
config-path: commands
|
||||
- name: "Run Release Pipeline Labeler"
|
||||
uses: ./actions/release-pipeline
|
||||
with:
|
||||
token: ${{secrets.VSCODE_ISSUE_TRIAGE_BOT_PAT}}
|
||||
appInsightsKey: ${{secrets.TRIAGE_ACTIONS_APP_INSIGHTS}}
|
||||
notYetReleasedLabel: unreleased
|
||||
insidersReleasedLabel: insiders-released
|
|
@ -10,30 +10,26 @@ jobs:
|
|||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
ref: v37
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
ref: stable
|
||||
path: ./actions
|
||||
- name: Install Actions
|
||||
run: npm install --production --prefix ./actions
|
||||
|
||||
# source of truth in ./author-verified.yml
|
||||
- name: Checkout Repo
|
||||
if: contains(github.event.issue.labels.*.name, 'author-verification-requested')
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
path: ./repo
|
||||
fetch-depth: 0
|
||||
- name: Run Author Verified
|
||||
if: contains(github.event.issue.labels.*.name, 'author-verification-requested')
|
||||
if: contains(github.event.issue.labels.*.name, 'author-verification-requested') && contains(github.event.issue.labels.*.name, 'insiders-released')
|
||||
uses: ./actions/author-verified
|
||||
with:
|
||||
appInsightsKey: ${{secrets.TRIAGE_ACTIONS_APP_INSIGHTS}}
|
||||
requestVerificationComment: "This bug has been fixed in to the latest release of [VS Code Insiders](https://code.visualstudio.com/insiders/)!\n\n@${author}, you can help us out by confirming things are working as expected in the latest Insiders release. If things look good, please leave a comment with the text `/verified` to let us know. If not, please ensure you're on version ${commit} of Insiders (today's or later - you can use `Help: About` in the command pallete to check), and leave a comment letting us know what isn't working as expected.\n\nHappy Coding!"
|
||||
pendingReleaseLabel: awaiting-insiders-release
|
||||
token: ${{secrets.VSCODE_ISSUE_TRIAGE_BOT_PAT}}
|
||||
requestVerificationComment: "This bug has been fixed in the latest release of [VS Code Insiders](https://code.visualstudio.com/insiders/)!\n\n@${author}, you can help us out by commenting `/verified` if things are now working as expected.\n\nIf things still don't seem right, please ensure you're on version ${commit} of Insiders (today's or later - you can use `Help: About` in the command palette to check), and leave a comment letting us know what isn't working as expected.\n\nHappy Coding!"
|
||||
releasedLabel: insiders-released
|
||||
verifiedLabel: verified
|
||||
authorVerificationRequestedLabel: author-verification-requested
|
||||
|
||||
# source of truth in ./commands.yml
|
||||
|
||||
# also make changes in ./on-comment.yml
|
||||
- name: Run Commands
|
||||
uses: ./actions/commands
|
||||
with:
|
||||
|
|
|
@ -10,8 +10,8 @@ jobs:
|
|||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
ref: v37
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
ref: stable
|
||||
path: ./actions
|
||||
- name: Install Actions
|
||||
run: npm install --production --prefix ./actions
|
||||
|
|
|
@ -12,8 +12,8 @@ jobs:
|
|||
- name: Checkout Actions
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
ref: v37
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
ref: stable
|
||||
path: ./actions
|
||||
- name: Checkout Repo
|
||||
if: github.event_name != 'issues'
|
||||
|
|
|
@ -3,30 +3,34 @@ on:
|
|||
pull_request:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
- main
|
||||
|
||||
jobs:
|
||||
richnav:
|
||||
runs-on: windows-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: actions/cache@v2
|
||||
id: caching-stage
|
||||
name: Cache VS Code dependencies
|
||||
with:
|
||||
path: node_modules
|
||||
key: ${{ runner.os }}-dependencies-${{ hashfiles('yarn.lock') }}
|
||||
restore-keys: ${{ runner.os }}-dependencies-
|
||||
- uses: actions/cache@v2
|
||||
id: caching-stage
|
||||
name: Cache VS Code dependencies
|
||||
with:
|
||||
path: node_modules
|
||||
key: ${{ runner.os }}-dependencies-${{ hashfiles('yarn.lock') }}
|
||||
restore-keys: ${{ runner.os }}-dependencies-
|
||||
|
||||
- name: Install dependencies
|
||||
if: steps.caching-stage.outputs.cache-hit != 'true'
|
||||
run: yarn --frozen-lockfile
|
||||
env:
|
||||
CHILD_CONCURRENCY: 1
|
||||
- uses: actions/setup-node@v1
|
||||
with:
|
||||
node-version: 10
|
||||
|
||||
- uses: microsoft/RichCodeNavIndexer@v0.1
|
||||
with:
|
||||
languages: typescript
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
continue-on-error: true
|
||||
- name: Install dependencies
|
||||
if: steps.caching-stage.outputs.cache-hit != 'true'
|
||||
run: yarn --frozen-lockfile
|
||||
env:
|
||||
CHILD_CONCURRENCY: 1
|
||||
|
||||
- uses: microsoft/RichCodeNavIndexer@v0.1
|
||||
with:
|
||||
languages: typescript
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
continue-on-error: true
|
||||
|
|
|
@ -12,9 +12,9 @@ jobs:
|
|||
if: contains(github.event.issue.labels.*.name, 'testplan-item') || contains(github.event.issue.labels.*.name, 'invalid-testplan-item')
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
repository: 'microsoft/vscode-github-triage-actions'
|
||||
repository: "microsoft/vscode-github-triage-actions"
|
||||
path: ./actions
|
||||
ref: v37
|
||||
ref: stable
|
||||
- name: Install Actions
|
||||
if: contains(github.event.issue.labels.*.name, 'testplan-item') || contains(github.event.issue.labels.*.name, 'invalid-testplan-item')
|
||||
run: npm install --production --prefix ./actions
|
||||
|
|
|
@ -5,26 +5,9 @@ Thumbs.db
|
|||
node_modules/
|
||||
.build/
|
||||
extensions/**/dist/
|
||||
out/
|
||||
out-build/
|
||||
out-editor/
|
||||
out-editor-src/
|
||||
out-editor-build/
|
||||
out-editor-esm/
|
||||
out-editor-esm-bundle/
|
||||
out-editor-min/
|
||||
out-monaco-editor-core/
|
||||
out-vscode/
|
||||
out-vscode-min/
|
||||
out-vscode-reh/
|
||||
out-vscode-reh-min/
|
||||
out-vscode-reh-pkg/
|
||||
out-vscode-reh-web/
|
||||
out-vscode-reh-web-min/
|
||||
out-vscode-reh-web-pkg/
|
||||
out-vscode-web/
|
||||
out-vscode-web-min/
|
||||
out-vscode-web-pkg/
|
||||
/out*/
|
||||
/extensions/**/out/
|
||||
# src/vs/server NOTE@coder: So our code isn't ignored.
|
||||
resources/server
|
||||
build/node_modules
|
||||
coverage/
|
||||
|
|
|
@ -1,2 +1,6 @@
|
|||
Eric Amodio <eamodio@microsoft.com> Eric Amodio <eamodio@gmail.com>
|
||||
Eric Amodio <eamodio@microsoft.com> Eric Amodio <eamodio@ioninteractive.com>
|
||||
Daniel Imms <daimms@microsoft.com> Daniel Imms <tyriar@tyriar.com>
|
||||
Tanha Kabir <tanha.kabir@microsoft.com> Tanha Kabir <tanhakabir.ca@gmail.com>
|
||||
Raymond Zhao <raymondzhao@microsoft.com>
|
||||
Tyler Leonhardt <tyleonha@microsoft.com> Tyler Leonhardt <me@tylerleonhardt.com>
|
||||
|
|
|
@ -3,7 +3,6 @@
|
|||
// for the documentation about the extensions.json format
|
||||
"recommendations": [
|
||||
"dbaeumer.vscode-eslint",
|
||||
"EditorConfig.EditorConfig",
|
||||
"msjsdiag.debugger-for-chrome"
|
||||
"EditorConfig.EditorConfig"
|
||||
]
|
||||
}
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue