From eb90e0f3b8b45dde3b366afe3092203953702ea2 Mon Sep 17 00:00:00 2001 From: Marcus Doucette Date: Sat, 4 Jan 2025 19:04:53 -0500 Subject: [PATCH 1/3] Move "cd vscode" to one place instead of two I thought it was confusing that there were two different places where you would be 'cd'ing into vscode. Since you can read through both of these one after another, someone who doesn't know that there isn't a vscode folder inside of the vscode repo might be confused as to where they should be. Having the 'cd vscode' appear just once when you create the repo made more sense to me. --- How-to-Contribute.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/How-to-Contribute.md b/How-to-Contribute.md index 66f61bb63a..f4e26b9f65 100644 --- a/How-to-Contribute.md +++ b/How-to-Contribute.md @@ -86,12 +86,12 @@ First, fork the VS Code repository so that you can make a pull request. Then, cl ``` git clone https://github.com/<<>>/vscode.git +cd vscode ``` Occasionally you will want to merge changes in the upstream repository (the official code repo) with your fork. ``` -cd vscode git checkout main git pull https://github.com/microsoft/vscode.git main ``` @@ -105,7 +105,6 @@ Manage any merge conflicts, commit them, and then push them to your fork. Install and build all of the dependencies using `npm`: ``` -cd vscode npm i ``` From cab923be2e06fb77dca6d7209832fe608753a46b Mon Sep 17 00:00:00 2001 From: Marcus Doucette Date: Sat, 4 Jan 2025 19:14:22 -0500 Subject: [PATCH 2/3] Add footnote for clarity "You can open the `vscode` folder" is ambiguous as to where the folder should be opened. Because of this I changed the wording to be a bit clearer and added a "code ." suggestion as that would be easier for most developers to follow at the point the previous steps put them into the vscode folder. --- How-to-Contribute.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/How-to-Contribute.md b/How-to-Contribute.md index f4e26b9f65..9630c6cd4b 100644 --- a/How-to-Contribute.md +++ b/How-to-Contribute.md @@ -110,7 +110,7 @@ npm i Then you have two options: -- If you want to build from inside VS Code, you can open the `vscode` folder and start the build task with Ctrl+Shift+B (CMD+Shift+B on macOS). The build task will stay running in the background even if you close VS Code. If you happen to close VS Code and open it again, just resume the build by pressing Ctrl+Shift+B (CMD+Shift+B) again. You can kill it by running the `Kill Build VS Code` task or pressing Ctrl+D in the task terminal. +- If you want to build from inside VS Code, open the `vscode` folder in vscode (`code .`) and start the build task with Ctrl+Shift+B (CMD+Shift+B on macOS). The build task will stay running in the background even if you close VS Code. If you happen to close VS Code and open it again, just resume the build by pressing Ctrl+Shift+B (CMD+Shift+B) again. You can kill it by running the `Kill Build VS Code` task or pressing Ctrl+D in the task terminal. - If you want to build from a terminal, run `npm run watch`. This will run both the core watch task and watch-extension tasks in a single terminal. The incremental builder will do an initial full build and will display a message that includes the phrase "Finished compilation" once the initial build is complete. The builder will watch for file changes and compile those changes incrementally, giving you a fast, iterative coding experience. From 804f15be85b4b05092f6104ba2fdddc82c8351f2 Mon Sep 17 00:00:00 2001 From: Marcus Doucette Date: Sat, 4 Jan 2025 19:37:48 -0500 Subject: [PATCH 3/3] Add warning for path with spaces When following this guide, the build step was failing with both methods. I didn't know why it wasn't working until I realized that my path contained spaces and that was breaking things. To help future users I added a warning and troubleshooting tip so that people can avoid this mistake in the future or people who also make this mistake will have less trouble resolving it. --- How-to-Contribute.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/How-to-Contribute.md b/How-to-Contribute.md index 9630c6cd4b..2da5bab57b 100644 --- a/How-to-Contribute.md +++ b/How-to-Contribute.md @@ -84,6 +84,10 @@ If you want to understand how VS Code works or want to debug an issue, you'll wa First, fork the VS Code repository so that you can make a pull request. Then, clone your fork locally: +> [!Warning] +> Make sure that the path to your local clone does not contain spaces. +> This can cause issues with later steps. + ``` git clone https://github.com/<<>>/vscode.git cd vscode @@ -117,6 +121,7 @@ The incremental builder will do an initial full build and will display a message **Troubleshooting:** +- Make sure that the path to your local clone of the repo does not contain spaces. - **Windows:** If you have installed Visual Studio 2017 as your build tool, you need to open **x64 Native Tools Command Prompt for VS 2017**. Do not confuse it with *VS2015 x64 Native Tools Command Prompt*, if installed. - **Linux:** You may hit a ENOSPC error when running the build. To get around this follow instructions in the [Common Questions](https://code.visualstudio.com/docs/setup/linux#_common-questions).