From 52061e396484d13dec37bc19653e6014fe68444a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E6=9D=83?= <327779727@qq.com> Date: Sat, 31 Aug 2024 16:02:27 +0800 Subject: [PATCH] Update development.md;Added VSCode extension development guide and sync Fork scenarios. --- docs/development/development.md | 46 +++++++++++++++++++++++++++------ 1 file changed, 38 insertions(+), 8 deletions(-) diff --git a/docs/development/development.md b/docs/development/development.md index 5dbdee70..b1238f26 100644 --- a/docs/development/development.md +++ b/docs/development/development.md @@ -6,23 +6,53 @@ has_children: true permalink: /development --- +[!IMPORTANT] +# Study VSCode extension development + - `VSCode extension development`: [English Document](https://code.visualstudio.com/api),[中文文档](https://github.com/Liiked/VS-Code-Extension-Doc-ZH) + - `debugging`: [debugging Document](https://code.visualstudio.com/docs/editor/debugging) + - `extension samples`: [VSCode extension samples](https://github.com/microsoft/vscode-extension-samples) # Quick Start Guide to Contributing +1. Fork -1. Fork: Click this URL [https://github.com/unit-mesh/auto-dev-vscode](https://github.com/unit-mesh/auto-dev-vscode), Click the `Fork` button to create your own copy of this repository +Click this URL [https://github.com/unit-mesh/auto-dev-vscode](https://github.com/unit-mesh/auto-dev-vscode), Click the `Fork` button to create your own copy of this repository -2. Clone: Use this command in the terminal tool to clone this project to your local machine: +2. Clone -``` -# Replace "" with your GitHub account -# such as "git clone git@github.com:unit-mesh/auto-dev-vscode.git" +Use this command in the terminal tool to clone this project to your local machine: `git clone git@github.com:/auto-dev-vscode.git`, Replace "``" with your GitHub account, such as "git clone git@github.com:unit-mesh/auto-dev-vscode.git" -git clone git@github.com:/auto-dev-vscode.git -``` +3. Sync Fork + +Only execute this command once: `cd auto-dev-vscode && git remote add upstream git@github.com:unit-mesh/auto-dev-vscode.git` + +> Scenarios Where You Might Need to `git checkout master && git pull upstream master` First +> +> This ensures that your local repository stays up-to-date with the upstream repository, fetching and merging the latest changes each time. +> +> - **After a Long Period of Inactivity**: After a long period of inactivity, execute `git checkout master && git pull upstream master` before continuing to ensure you have the latest changes. +> - **Before Creating a New Branch**: Before creating a new branch, it's a good practice to `git checkout master && git pull upstream master && git checkout -b feat-xxxx` to ensure the new branch is based on the latest state of the upstream repository. +> - **Before Merging Changes**: Before merging other branches into the current branch, it's recommended to `git checkout master && git pull upstream master && git merge feat-xxxx` to ensure the local branch is up-to-date. +> - **Before Pushing Changes**: Before pushing your local changes to the remote repository, it's recommended to `git checkout master && git pull upstream master && git push` to avoid conflicts or outdated changes. + + + +4. Branch + +Create a new branch for your changes, such as: `git checkout master && git pull upstream master && git checkout -b feat-xxxx master` + +4. Merge + +Merge your branch into the master branch, such as: `git checkout master && git merge feat-xxxx` + +5. Push + +`git checkout master && git pull upstream master && git push` + +5. Pull Request(pr) -3. PR: Coding or edit documentation of this project, then commit your changes, and finally submit a pull request on GitHub +Coding or edit documentation of this project, then commit your changes, and finally submit a pull request on GitHub # Development