mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-21 12:15:00 +00:00
feature: simple interactive rebase support (#188)
* Only allow to start interactive rebase from merged commit in current branch * The order of commits in the interactive rebase window is as same as it's in histories page. * Unlike anthor git frontend app `Fork`, you should edit the final message on the last commit rather than the previous commit that will be meld into while squashing commits
This commit is contained in:
parent
6c9f7e6da3
commit
7070a07e15
17 changed files with 816 additions and 7 deletions
|
@ -277,6 +277,18 @@ namespace SourceGit.ViewModels
|
|||
e.Handled = true;
|
||||
};
|
||||
menu.Items.Add(revert);
|
||||
|
||||
var interactiveRebase = new MenuItem();
|
||||
interactiveRebase.Header = new Views.NameHighlightedTextBlock("CommitCM.InteractiveRebase", current.Name);
|
||||
interactiveRebase.Icon = App.CreateMenuIcon("Icons.InteractiveRebase");
|
||||
interactiveRebase.IsVisible = current.Head != commit.SHA;
|
||||
interactiveRebase.Click += (o, e) =>
|
||||
{
|
||||
var dialog = new Views.InteractiveRebase() { DataContext = new InteractiveRebase(_repo, current, commit) };
|
||||
dialog.ShowDialog(App.GetTopLevel() as Window);
|
||||
e.Handled = true;
|
||||
};
|
||||
menu.Items.Add(interactiveRebase);
|
||||
}
|
||||
|
||||
if (current.Head != commit.SHA)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue