GitLens supercharges the Git capabilities built into Visual Studio Code. It helps you to visualize code authorship at a glance via Git blame annotations and code lens, seamlessly navigate and explore Git repositories, gain valuable insights via powerful comparison commands, and so much more.

Settings

For advanced customizations, refer to the GitLens docs and edit your User Settings

Adds an unobtrusive blame annotation at the end of the current line

Use the GitLens: Toggle Line Blame Annotations command to override this setting for the current window

When enabled the annotation can be scrolled into view when it is outside the viewport

For more options, open User Settings and search for gitlens.currentLine

Adds authorship code lens to the top of files and on code blocks

Use the GitLens: Toggle Git Code Lens command to override this setting for the current window

At the top of the file

At the start of modules, classes, interfaces, etc

At the start of functions, methods, etc

For more options, open User Settings and search for gitlens.codeLens

Adds a Git blame annotation about the current line to the status bar

Avoids clearing the previous blame information when changing lines to reduce status bar "flashing"

For more options, open User Settings and search for gitlens.statusBar

Adds detailed blame information accessible via hovers

Views

Adds rich views to visualize, navigate, and explore

GitLens views can be configured to be shown in different side bar layouts to best match your workflow. You can easily change the default layout (where all views are shown together on the GitLens side bar) below

Adds a Repositories view to visualize, navigate, and explore Git repositories

Chooses the best layout based on the number of files at each nesting level

Compacts (flattens) unnecessary nesting when using a tree layouts

For more options, open User Settings and search for gitlens.views.repositories or gitlens.views

Adds a File History view to visualize, navigate, and explore the revision history of the current file

Adds a Line History view to visualize, navigate, and explore the revision history of the selected lines of current file

Adds a Search Commits view to search and explore commit histories by message, author, files, id, etc

Compacts (flattens) unnecessary nesting when using a tree layouts

For more options, open User Settings and search for gitlens.views.search or gitlens.views

Adds a Compare view to visualize comparisons between branches, tags, commits, and more

Compacts (flattens) unnecessary nesting when using a tree layouts

For more options, open User Settings and search for gitlens.views.compare or gitlens.views

Gutter Blame

Adds on-demand gutter blame annotations for the whole file

Use the command to turn the annotations on or off

Press Esc to turn off the annotations

Indicator color reflects the age of the most recent change (hot or cold), while indicator brightness ranges from bright (newer) to dim (older) based on the relative age

Compacts (deduplicates) matching adjacent blame annotations

For more options, open User Settings and search for gitlens.blame

Gutter Heatmap

Adds on-demand heatmap (age) indicator to the edge of the gutter to show how recently lines were changed

Use the command to turn the annotations on or off

Press Esc to turn off the annotations

Indicator color reflects the age of the most recent change (hot or cold), while indicator brightness ranges from bright (newer) to dim (older) based on the relative age

Recent Changes

Adds on-demand recent changes annotations to highlight lines changed by the most recent commit

Use the command to turn the annotations on or off

Press Esc to turn off the annotations

Dates & Times

Example date:
Example short date:

Keyboard Shortcuts

Search for gitlens in the Keyboard Shortcuts editor to see the shortcuts and to customize them further

Modes

Supports user-defined modes for quickly toggling between sets of settings

Use the GitLens: Switch Mode command to quickly switch the active mode

Use the GitLens: Toggle Review Mode command to toggle Review mode

Use the GitLens: Toggle Zen Mode command to toggle Zen mode

For more options or to add your own custom modes, open User Settings and search for gitlens.modes

#{endOfBody}