-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Coding
- Node.js 12.20
- Python 2.7 or later
- Windows, macOS, or Linux
- Visual Studio Code
- The following VS Code extensions:
- Have an issue which has a "needs PR" label (feel free to indicate you would like to provide a PR for the issue so others don't work on it as well)
- Do lean into TypeScript's types; typing is good. 😄
- Do not silence ESLint warnings unnecessarily; have justifications as to why.
-
Do not rely on the
!
operator, if possible; assume the typing is correct. -
Do use
undefined
when necessary; do not usenull
.
git clone https://github.com/microsoft/vscode-python
cd vscode-python
npm ci
python3 -m venv .venv
# Activate the virtual environment as appropriate for your shell, For example, If you're on cmd, you can use...
# ".venv/Scripts/activate.bat"
# On bash/zsh it's ...
source .venv/bin/activate
# The Python code in the extension is formatted using Black.
python3 -m pip install black
# Install Python dependencies using `python3`. If it fails, it'll fallback to using `python` instead which also works.
# If you want to use a different interpreter then specify it in the
# CI_PYTHON_PATH environment variable.
npx gulp installPythonLibs
If you see warnings that The engine "vscode" appears to be invalid.
, you can ignore these. If python3
is not available for some reason, you can use python
instead.
Run the Compile
build task from the Run Build Task... command picker (short cut CTRL+SHIFT+B
or ⇧⌘B
). This will leave build task running in the background and which will re-run as files are edited and saved. You can see the output from either task in the Terminal panel (use the selector to choose which output to look at).
You can also compile from the command-line. For a full compile you can use:
npx gulp prePublishNonBundle
For incremental builds you can use the following commands depending on your needs:
npm run compile
Sometimes you will need to run npm run clean
and even rm -r out
.
This is especially true if you have added or removed files.