diff --git a/TGit/Commands/ContextMenuCommands.cs b/TGit/Commands/ContextMenuCommands.cs index 9ed80ae..614d232 100644 --- a/TGit/Commands/ContextMenuCommands.cs +++ b/TGit/Commands/ContextMenuCommands.cs @@ -28,6 +28,7 @@ public void AddCommands() CommandHelper.AddCommand(_mcs, ShowLogContextCommand, PkgCmdIDList.ShowLogContext, ActiveDocument_BeforeQueryStatus); CommandHelper.AddCommand(_mcs, DiskBrowserContextCommand, PkgCmdIDList.DiskBrowserContext, ActiveDocument_BeforeQueryStatus); CommandHelper.AddCommand(_mcs, RepoBrowserContextCommand, PkgCmdIDList.RepoBrowserContext, ActiveDocument_BeforeQueryStatus); + CommandHelper.AddCommand(_mcs, RevGraphContextCommand, PkgCmdIDList.RevGraphContext, ActiveDocument_BeforeQueryStatus); CommandHelper.AddCommand(_mcs, BlameContextCommand, PkgCmdIDList.BlameContext, ActiveDocument_BeforeQueryStatus); @@ -64,6 +65,12 @@ private void RepoBrowserContextCommand(object sender, EventArgs e) if (string.IsNullOrEmpty(currentFilePath)) return; ProcessHelper.StartTortoiseGitProc(_envHelper, $"/command:repobrowser", currentFilePath); } + private void RevGraphContextCommand(object sender, EventArgs e) + { + var currentFilePath = _dte.ActiveDocument.FullName; + if (string.IsNullOrEmpty(currentFilePath)) return; + ProcessHelper.StartTortoiseGitProc(_envHelper, $"/command:revisiongraph /path:\"{currentFilePath}\""); + } private void BlameContextCommand(object sender, EventArgs e) { var currentFilePath = _dte.ActiveDocument.FullName; diff --git a/TGit/Commands/MainMenuCommands.cs b/TGit/Commands/MainMenuCommands.cs index 7dc039d..3743ab2 100644 --- a/TGit/Commands/MainMenuCommands.cs +++ b/TGit/Commands/MainMenuCommands.cs @@ -31,6 +31,7 @@ public void AddCommands() CommandHelper.AddCommand(_mcs, ShowLogCommand, PkgCmdIDList.ShowLog); CommandHelper.AddCommand(_mcs, DiskBrowserCommand, PkgCmdIDList.DiskBrowser); CommandHelper.AddCommand(_mcs, RepoBrowserCommand, PkgCmdIDList.RepoBrowser); + CommandHelper.AddCommand(_mcs, RevGraphCommand, PkgCmdIDList.RevGraph); CommandHelper.AddCommand(_mcs, CreateStashCommand, PkgCmdIDList.CreateStash); CommandHelper.AddCommand(_mcs, ApplyStashCommand, PkgCmdIDList.ApplyStash, CommandHelper.ApplyStash_BeforeQueryStatus); @@ -102,6 +103,11 @@ private void RepoBrowserCommand(object sender, EventArgs e) PreCommand(); ProcessHelper.StartTortoiseGitProc(_envHelper, $"/command:repobrowser"); } + private void RevGraphCommand(object sender, EventArgs e) + { + PreCommand(); + ProcessHelper.StartTortoiseGitProc(_envHelper, $"/command:revisiongraph"); + } private void CreateStashCommand(object sender, EventArgs e) { PreCommand(); diff --git a/TGit/IconMappings.csv b/TGit/IconMappings.csv index a281321..544886b 100644 --- a/TGit/IconMappings.csv +++ b/TGit/IconMappings.csv @@ -19,4 +19,5 @@ fec49b6d-c04a-42bd-b021-b8b2e5cfb291,18,d53d7256-d44d-4245-bdd2-bfd22943659c,18 fec49b6d-c04a-42bd-b021-b8b2e5cfb291,19,d53d7256-d44d-4245-bdd2-bfd22943659c,19 fec49b6d-c04a-42bd-b021-b8b2e5cfb291,20,d53d7256-d44d-4245-bdd2-bfd22943659c,20 fec49b6d-c04a-42bd-b021-b8b2e5cfb291,21,d53d7256-d44d-4245-bdd2-bfd22943659c,21 -fec49b6d-c04a-42bd-b021-b8b2e5cfb291,22,d53d7256-d44d-4245-bdd2-bfd22943659c,22 \ No newline at end of file +fec49b6d-c04a-42bd-b021-b8b2e5cfb291,22,d53d7256-d44d-4245-bdd2-bfd22943659c,22 +fec49b6d-c04a-42bd-b021-b8b2e5cfb291,22,d53d7256-d44d-4245-bdd2-bfd22943659c,23 \ No newline at end of file diff --git a/TGit/Images.imagemanifest b/TGit/Images.imagemanifest index e222613..636aa1f 100644 --- a/TGit/Images.imagemanifest +++ b/TGit/Images.imagemanifest @@ -30,6 +30,7 @@ + @@ -98,6 +99,9 @@ + + + \ No newline at end of file diff --git a/TGit/Images.vsct b/TGit/Images.vsct index e5eb971..e1b8ad9 100644 --- a/TGit/Images.vsct +++ b/TGit/Images.vsct @@ -35,6 +35,7 @@ + diff --git a/TGit/PkgCmdID.cs b/TGit/PkgCmdID.cs index bbbd75e..1a5988e 100644 --- a/TGit/PkgCmdID.cs +++ b/TGit/PkgCmdID.cs @@ -67,5 +67,7 @@ static class PkgCmdIDList public const uint SvnRebase = 0x145; public const uint Rebase = 0x146; + public const uint RevGraphContext = 0x147; + public const uint RevGraph = 0x148; } } \ No newline at end of file diff --git a/TGit/Resources/Images/RevGraph.xaml b/TGit/Resources/Images/RevGraph.xaml new file mode 100644 index 0000000..d86b640 --- /dev/null +++ b/TGit/Resources/Images/RevGraph.xaml @@ -0,0 +1,13 @@ + + + + + + + + + + + + + \ No newline at end of file diff --git a/TGit/Resources/octicons.png b/TGit/Resources/octicons.png index 525d378..8d5197f 100644 Binary files a/TGit/Resources/octicons.png and b/TGit/Resources/octicons.png differ diff --git a/TGit/TGIT.csproj b/TGit/TGIT.csproj index 890da7f..39bb5fd 100644 --- a/TGit/TGIT.csproj +++ b/TGit/TGIT.csproj @@ -319,6 +319,10 @@ MSBuild:Compile Designer + + MSBuild:Compile + Designer + MSBuild:Compile Designer diff --git a/TGit/TGIT.vsct b/TGit/TGIT.vsct index 0a35ae4..0fd6e18 100644 --- a/TGit/TGIT.vsct +++ b/TGit/TGIT.vsct @@ -245,7 +245,7 @@ - + + +