mirror of
https://github.com/microsoft/vscode.git
synced 2026-02-22 02:36:07 +00:00
* Hacked up the starting point * More progress * More progress * Simplified algo, basic support for colors * Add the concept of secondary colors for merge commits * Further optimizations of the algo * Bug fixes to clean-up algo * Add support for curved branches * Keep track of nodes that are moved so that the second parent for the merge commit is rendered in the correct swimlane * Account for offset when drawing a base commit * Algo rework completed * Revert some of the hacks that were put in place to quickly get going * Add caching to the history items used in the graph Remove more hacks that were in place * Added initial tests * More work so that incoming/outgoing works along history * Uncomment more code * Bug fixes to edge cases * Experiment with a new rendering for curved branches * Handle repository with a single commit * Maintain swimlanes * Fix condition * Saving my changes * More polish and clean-up * Remove code that is not needed * Revert change * Revert more changes * More fixes * Rename interface * One last minor change * Pull request feedback * More refactoring * More pull request feedback * Fix layering issues
Git integration for Visual Studio Code
Notice: This extension is bundled with Visual Studio Code. It can be disabled but not uninstalled.
Features
See Git support in VS Code to learn about the features of this extension.
API
The Git extension exposes an API, reachable by any other extension.
-
Copy
src/api/git.d.tsto your extension's sources; -
Include
git.d.tsin your extension's compilation. -
Get a hold of the API with the following snippet:
const gitExtension = vscode.extensions.getExtension<GitExtension>('vscode.git').exports; const git = gitExtension.getAPI(1);Note: To ensure that the
vscode.gitextension is activated before your extension, addextensionDependencies(docs) into thepackage.jsonof your extension:"extensionDependencies": [ "vscode.git" ]