Skip to content

It is an extension for VS code, which can show git blame in editor and can run git gui blame.

License

Notifications You must be signed in to change notification settings

Tkinfolks/git-blame-w77

 
 

Repository files navigation

Git Blame W77

Description

It is an extension for VS code, which can show git blame in editor and can run git gui blame.

Features

  • High performance.
  • Support for very large files (e.g. 20,000 lines of code).
  • Show git blame simillar like NetBeans IDE.
  • Show previously blame in the editor, it is easy to go backwards.
  • Use resources only when is switch on.
  • Specify colors for Dark and Light theme
  • Possibility to run Git Gui Blame (e.g for check changes in line).
  • No library dependencies.
  • Tested on Linux and Windows.

How to use

  1. Press Alt + B or click in context menu Git Blame Toggle on the text editor to show or hide the blame decoration
  2. To see details of commit hover mouse on the decoration (the option "editor.hover.enabled" have to be enabled) or hover mouse on the status bar (at the bottom).
  3. Alternatively press Ctrl + Shift + B to run Git Gui Blame

Git Blame screeshot 1

Git Blame screeshot 1b

Git Blame screeshot 2

Commands

name description keybinding
gitBlameW77.toggleBlameDecoration Git Blame Toggle Alt + B
gitBlameW77.runGitGuiBlameForFile Run Git Gui Blame Ctrl + Shift + B
gitBlameW77.runGitGuiBlameForHash Run Git Gui Blame For Line Ctrl + Alt + B

Configuration

name default description
gitBlameW77.colors {
"dark": ["#999", "#666"],
"light": ["#444", "#111"]
}
Specifies colors for the blame decoration.
gitBlameW77.colorsUsedAsBackground false Specifies whether colors are used as background of decoration. Default colors are used as text of decoration.
gitBlameW77.gitBlameUrl null Specifies git blame URL e.g 'https://github.com/wojtek77/git-blame-w77/commit/${hash}'. When it is NULL (default) it tries to automatically find the URL. When there is an empty string it disables this functionality. This functionality degrades performance when rendering decorations.
gitBlameW77.dateLocale "" (empty string) Specifies locale for date e.g 'en-US'. More locales here https://www.w3schools.com/jsref/jsref_tolocalestring.asp or https://stackoverflow.com/questions/27939773/tolocaledatestring-short-format. When there is an empty string (default) then it take locale from system.
gitBlameW77.decorationShowHash true Specifies whether to show commit hash or not in decoration.
gitBlameW77.showInContextMenu true Specifies whether to show in the context menu 'Git Blame Toggle'.
gitBlameW77.hoverEnabled true Determines whether hover show in extension. If FALSE it speeds up decoration rendering a lot.
gitBlameW77.hoverShowLinkToGitGuiBlame true Specifies whether to show link to Git Gui Blame in hover of decoration. This functionality degrades performance when rendering decorations.

Examples for "gitBlameW77.colors"

    // default colors since v2.2.0
    // specify colors for light or dark theme
    "gitBlameW77.colors": {
        "dark": [
            "#999",
            "#666"
        ],
        "light": [
            "#444",
            "#111"
        ]
    },

    // default colors before v.2.2.0
    // can be still used since v.2.2.0 without keys "dark" and "light"
    "gitBlameW77.colors": [
        "#17a7ea",
        "#43a965",
        "#ba9286",
        "#cfa84e",
        "#bd6ab9",
        "#8f74e0",
        "#3187f0",
        "#e58965",
        "#e66e84",
        "#7a82da"
    ],

    // one color "editor.foreground" from theme
    "gitBlameW77.colors": [
    ],

Examples for "gitBlameW77.colorsUsedAsBackground"

    // default colors are used as text of decoration
    "gitBlameW77.colorsUsedAsBackground": false,
    
    // colors are used as background of decoration
    "gitBlameW77.decorationShowHash": true,

Default colors are used as text of decoration
Git Blame screeshot 8

Colors are used as background of decoration
Git Blame screeshot 9

Examples for "gitBlameW77.gitBlameUrl"

    // when it is NULL (default) it tries to automatically find the URL
    "gitBlameW77.gitBlameUrl": null,
    
    // own URL e.g 'https://github.com/wojtek77/git-blame-w77/commit/${hash}'
    // where "${hash}" will be replaced by realy hash
    "gitBlameW77.gitBlameUrl": "https://github.com/wojtek77/git-blame-w77/commit/${hash}",
    
    // when there is an empty string it disables this functionality
    // this functionality degrades performance when rendering decorations
    "gitBlameW77.gitBlameUrl": "",

When it is switch on
Git Blame screeshot 3

When it is switch off
Git Blame screeshot 4

Examples for "gitBlameW77.dateLocale"

    // when there is an empty string (default) then it take locale from system
    "gitBlameW77.dateLocale": "",
    
    // US English
    // more info https://www.w3schools.com/jsref/jsref_tolocalestring.asp
    "gitBlameW77.dateLocale": "en-US",

Locale "en-US"
Git Blame screeshot 5

Locale "sv-SE"
Git Blame screeshot 6

Examples for "gitBlameW77.decorationShowHash"

    // default shows commit hash in decoration
    "gitBlameW77.decorationShowHash": true,
    
    // does not show commit hash in decoration
    "gitBlameW77.decorationShowHash": false,

Does not show commit hash in decoration
Git Blame screeshot 7

Other

Colors made by Bluloco Dark Theme and Bluloco Dark Muted W77

About

It is an extension for VS code, which can show git blame in editor and can run git gui blame.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 99.7%
  • JavaScript 0.3%