Skip to content

Commit a69afdb

Browse files
committed
Closes #144 - support disabling the custom view
1 parent 26c6346 commit a69afdb

File tree

4 files changed

+12
-1
lines changed

4 files changed

+12
-1
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
44

55
The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/).
66

7+
## [Unreleased]
8+
### Added
9+
- Adds `gitlens.gitExplorer.enabled` setting to specify whether or not to show the `GitLens` custom view - closes [#144](https://github.com/eamodio/vscode-gitlens/issues/144)
10+
711
## [5.1.0] - 2017-09-15
812
### Added
913
- Adds full (multi-line) commit message to the `details` hover annotations -- closes [#116](https://github.com/eamodio/vscode-gitlens/issues/116)

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -350,6 +350,7 @@ GitLens is highly customizable and provides many configuration settings to allow
350350

351351
|Name | Description
352352
|-----|------------
353+
|`gitlens.gitExplorer.enabled`|Specifies whether or not to show the `GitLens` custom view"
353354
|`gitlens.gitExplorer.view`|Specifies the starting view (mode) of the `GitLens` custom view<br />`history` - shows the commit history of the active file<br />`repository` - shows a repository explorer"
354355
|`gitlens.gitExplorer.showTrackingBranch`|Specifies whether or not to show the tracking branch when displaying local branches in the `GitLens` custom view"
355356
|`gitlens.gitExplorer.commitFormat`|Specifies the format of committed changes in the `GitLens` custom view<br />Available tokens<br /> ${id} - commit id<br /> ${author} - commit author<br /> ${message} - commit message<br /> ${ago} - relative commit date (e.g. 1 day ago)<br /> ${date} - formatted commit date (format specified by `gitlens.statusBar.dateFormat`)<br /> ${authorAgo} - commit author, relative commit date<br />See https://github.com/eamodio/vscode-gitlens/wiki/Advanced-Formatting for advanced formatting

package.json

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -423,6 +423,11 @@
423423
"default": "${filePath}",
424424
"description": "Specifies the format of a committed file in the `GitLens` custom view\nAvailable tokens\n ${file} - file name\n ${filePath} - file name and path\n ${path} - file path"
425425
},
426+
"gitlens.gitExplorer.enabled": {
427+
"type": "boolean",
428+
"default": true,
429+
"description": "Specifies whether or not to show the `GitLens` custom view"
430+
},
426431
"gitlens.gitExplorer.showTrackingBranch": {
427432
"type": "boolean",
428433
"default": true,
@@ -1841,7 +1846,7 @@
18411846
{
18421847
"id": "gitlens.gitExplorer",
18431848
"name": "GitLens",
1844-
"when": "gitlens:enabled"
1849+
"when": "gitlens:enabled && config.gitlens.gitExplorer.enabled"
18451850
}
18461851
]
18471852
}

src/configuration.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -317,6 +317,7 @@ export interface IConfig {
317317
defaultDateFormat: string | null;
318318

319319
gitExplorer: {
320+
enabled: boolean;
320321
view: GitExplorerView;
321322
showTrackingBranch: boolean;
322323
commitFormat: string;

0 commit comments

Comments
 (0)