diff --git a/package.json b/package.json index cade14d..b312fe7 100644 --- a/package.json +++ b/package.json @@ -89,6 +89,7 @@ "onCommand:gitlens.showSettingsPage#stashes-view", "onCommand:gitlens.showSettingsPage#tags-view", "onCommand:gitlens.showSettingsPage#worktrees-view", + "onCommand:gitlens.showSettingsPage#commit-graph", "onCommand:gitlens.showWelcomePage", "onCommand:gitlens.showBranchesView", "onCommand:gitlens.showCommitDetailsView", @@ -4135,6 +4136,12 @@ "icon": "$(gear)" }, { + "command": "gitlens.showSettingsPage#commit-graph", + "title": "Open Commit Graph Settings", + "category": "GitLens+", + "icon": "$(gear)" + }, + { "command": "gitlens.showTimelinePage", "title": "Open Visual File History of Active File", "category": "GitLens+", @@ -6763,6 +6770,10 @@ "when": "false" }, { + "command": "gitlens.showSettingsPage#commit-graph", + "when": "false" + }, + { "command": "gitlens.showTimelinePage", "when": "gitlens:enabled && gitlens:activeFileStatus =~ /tracked/" }, @@ -8590,6 +8601,11 @@ "command": "gitlens.refreshGraphPage", "when": "gitlens:graphPage:focused", "group": "navigation@-99" + }, + { + "command": "gitlens.showSettingsPage#commit-graph", + "when": "gitlens:graphPage:focused", + "group": "navigation@-98" } ], "editor/title/context": [ diff --git a/src/constants.ts b/src/constants.ts index a07d235..bdbd437 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -198,6 +198,7 @@ export const enum Commands { ShowSettingsPageAndJumpToTagsView = 'gitlens.showSettingsPage#tags-view', ShowSettingsPageAndJumpToWorkTreesView = 'gitlens.showSettingsPage#worktrees-view', ShowSettingsPageAndJumpToViews = 'gitlens.showSettingsPage#views', + ShowSettingsPageAndJumpToCommitGraph = 'gitlens.showSettingsPage#commit-graph', ShowSettingsPageAndJumpToAutolinks = 'gitlens.showSettingsPage#autolinks', ShowStashesView = 'gitlens.showStashesView', ShowTagsView = 'gitlens.showTagsView', diff --git a/src/webviews/settings/settingsWebview.ts b/src/webviews/settings/settingsWebview.ts index 1449ac9..22ab7a2 100644 --- a/src/webviews/settings/settingsWebview.ts +++ b/src/webviews/settings/settingsWebview.ts @@ -37,6 +37,7 @@ export class SettingsWebview extends WebviewWithConfigBase { Commands.ShowSettingsPageAndJumpToTagsView, Commands.ShowSettingsPageAndJumpToWorkTreesView, Commands.ShowSettingsPageAndJumpToViews, + Commands.ShowSettingsPageAndJumpToCommitGraph, Commands.ShowSettingsPageAndJumpToAutolinks, ].map(c => { // The show and jump commands are structured to have a # separating the base command from the anchor