Parcourir la source

Reworks some commands for consistency

main
Eric Amodio il y a 6 ans
Parent
révision
b162c7c962
6 fichiers modifiés avec 13 ajouts et 43 suppressions
  1. +3
    -3
      CHANGELOG.md
  2. +7
    -34
      package.json
  3. +0
    -3
      src/commands/common.ts
  4. +1
    -1
      src/commands/openCommitInRemote.ts
  5. +1
    -1
      src/commands/openFileInRemote.ts
  6. +1
    -1
      src/commands/showQuickCommitFileDetails.ts

+ 3
- 3
CHANGELOG.md Voir le fichier

@ -9,11 +9,11 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this p
- Adds a tree layout option to tags in the *GitLens* explorer — closes [#358](https://github.com/eamodio/vscode-gitlens/issues/358)
- Adds an icon for the *Compare File with Previous Revision* command (`gitlens.diffWithPrevious`) and moves it into the editor toolbar
- Adds an icon for the *Compare File with Next Revision* command (`gitlens.diffWithNext`) and moves it into the editor toolbar
- Adds a *Show Line Commit Details* command (`gitlens.showQuickLineCommitFileDetails`) — behaves the same as the *Show Commit File Details* command (`gitlens.showQuickCommitFileDetails`) but with a more accurate menu name
- Adds a *Open Line Commit in Remote* command (`gitlens.openLineCommitInRemote`) — behaves the same as the *Open Commit in Remote* command (`gitlens.openCommitInRemote`) but with a more accurate menu name
- Adds a *Open Line in Remote* command (`gitlens.openLineInRemote`) — behaves the same as the *Open File in Remote* command (`gitlens.openFileInRemote`) but with a more accurate menu name
### Changed
- Renames *Compare Line Revision with Previous* command (`gitlens.diffLineWithPrevious`) to *Compare Commit with Previous* for consistency with other commands
- Renames *Compare Line Revision with Working File* command (`gitlens.diffLineWithWorking`) to *Compare Commit with Working File* for consistency with other commands
- Renames *Show Commit File Details* command (`gitlens.showQuickCommitFileDetails`) to *Show Commit Details* for consistency with other commands
- Renames the `gitlens.advanced.menus` setting to `gitlens.menus`
- Reworks GitLens menu contributions and configuration

+ 7
- 34
package.json Voir le fichier

@ -1152,7 +1152,7 @@
},
{
"command": "gitlens.diffLineWithPrevious",
"title": "Compare Line Revision with Previous",
"title": "Compare Commit with Previous",
"category": "GitLens"
},
{
@ -1167,7 +1167,7 @@
},
{
"command": "gitlens.diffLineWithWorking",
"title": "Compare Line Revision with Working File",
"title": "Compare Commit with Working File",
"category": "GitLens"
},
{
@ -1242,12 +1242,7 @@
},
{
"command": "gitlens.showQuickCommitFileDetails",
"title": "Show Commit File Details",
"category": "GitLens"
},
{
"command": "gitlens.showQuickLineCommitFileDetails",
"title": "Show Line Commit Details",
"title": "Show Commit Details",
"category": "GitLens"
},
{
@ -1321,16 +1316,6 @@
"category": "GitLens"
},
{
"command": "gitlens.openLineCommitInRemote",
"title": "Open Line Commit in Remote",
"category": "GitLens"
},
{
"command": "gitlens.openLineInRemote",
"title": "Open Line in Remote",
"category": "GitLens"
},
{
"command": "gitlens.openRepoInRemote",
"title": "Open Repository in Remote",
"category": "GitLens"
@ -1840,11 +1825,7 @@
},
{
"command": "gitlens.showQuickCommitFileDetails",
"when": "false"
},
{
"command": "gitlens.showQuickLineCommitFileDetails",
"when": "gitlens:activeIsBlameable"
"when": "editorTextFocus && gitlens:activeIsBlameable"
},
{
"command": "gitlens.showQuickFileHistory",
@ -1899,14 +1880,6 @@
"when": "gitlens:activeIsTracked && gitlens:activeHasRemote"
},
{
"command": "gitlens.openLineCommitInRemote",
"when": "gitlens:activeIsTracked && gitlens:activeHasRemote"
},
{
"command": "gitlens.openLineInRemote",
"when": "gitlens:activeIsTracked && gitlens:activeHasRemote"
},
{
"command": "gitlens.openFileRevision",
"when": "gitlens:activeIsTracked"
},
@ -2191,17 +2164,17 @@
"group": "1_gitlens@2"
},
{
"command": "gitlens.openLineInRemote",
"command": "gitlens.openFileInRemote",
"when": "editorTextFocus && gitlens:activeHasRemote && config.gitlens.menus.editor.remote",
"group": "1_gitlens_1@1"
},
{
"command": "gitlens.openLineCommitInRemote",
"command": "gitlens.openCommitInRemote",
"when": "editorTextFocus && gitlens:activeHasRemote && config.gitlens.menus.editor.remote",
"group": "1_gitlens_1@2"
},
{
"command": "gitlens.showQuickLineCommitFileDetails",
"command": "gitlens.showQuickCommitFileDetails",
"when": "editorTextFocus && gitlens:activeIsBlameable && config.gitlens.menus.editor.details",
"group": "1_gitlens_1@3"
},

+ 0
- 3
src/commands/common.ts Voir le fichier

@ -37,8 +37,6 @@ export enum Commands {
OpenFileInRemote = 'gitlens.openFileInRemote',
OpenFileRevision = 'gitlens.openFileRevision',
OpenInRemote = 'gitlens.openInRemote',
OpenLineCommitInRemote = 'gitlens.openLineCommitInRemote',
OpenLineInRemote = 'gitlens.openLineInRemote',
OpenRepoInRemote = 'gitlens.openRepoInRemote',
OpenWorkingFile = 'gitlens.openWorkingFile',
ResetSuppressedWarnings = 'gitlens.resetSuppressedWarnings',
@ -46,7 +44,6 @@ export enum Commands {
ShowLastQuickPick = 'gitlens.showLastQuickPick',
ShowQuickCommitDetails = 'gitlens.showQuickCommitDetails',
ShowQuickCommitFileDetails = 'gitlens.showQuickCommitFileDetails',
ShowQuickLineCommitFileDetails = 'gitlens.showQuickLineCommitFileDetails',
ShowQuickFileHistory = 'gitlens.showQuickFileHistory',
ShowQuickBranchHistory = 'gitlens.showQuickBranchHistory',
ShowQuickCurrentBranchHistory = 'gitlens.showQuickRepoHistory',

+ 1
- 1
src/commands/openCommitInRemote.ts Voir le fichier

@ -23,7 +23,7 @@ export class OpenCommitInRemoteCommand extends ActiveEditorCommand {
}
constructor() {
super([Commands.OpenCommitInRemote, Commands.OpenLineCommitInRemote]);
super(Commands.OpenCommitInRemote);
}
protected async preExecute(context: CommandContext, args: OpenCommitInRemoteCommandArgs = {}): Promise<any> {

+ 1
- 1
src/commands/openFileInRemote.ts Voir le fichier

@ -14,7 +14,7 @@ export interface OpenFileInRemoteCommandArgs {
export class OpenFileInRemoteCommand extends ActiveEditorCommand {
constructor() {
super([Commands.OpenFileInRemote, Commands.OpenLineInRemote]);
super(Commands.OpenFileInRemote);
}
protected async preExecute(context: CommandContext, args: OpenFileInRemoteCommandArgs = { range: true }): Promise<any> {

+ 1
- 1
src/commands/showQuickCommitFileDetails.ts Voir le fichier

@ -31,7 +31,7 @@ export class ShowQuickCommitFileDetailsCommand extends ActiveEditorCachedCommand
}
constructor() {
super([Commands.ShowQuickCommitFileDetails, Commands.ShowQuickLineCommitFileDetails]);
super(Commands.ShowQuickCommitFileDetails);
}
protected async preExecute(context: CommandContext, args: ShowQuickCommitFileDetailsCommandArgs = {}): Promise<any> {

Chargement…
Annuler
Enregistrer