mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-06-24 03:45:00 +00:00
refactor: remove duplicated context menu to ignore untracked files under folder
Signed-off-by: leo <longshuang@msn.cn>
This commit is contained in:
parent
6729d4e896
commit
e81674912c
13 changed files with 1 additions and 24 deletions
|
@ -788,17 +788,6 @@ namespace SourceGit.ViewModels
|
|||
};
|
||||
addToIgnore.Items.Add(singleFile);
|
||||
|
||||
var byParentFolder = new MenuItem();
|
||||
byParentFolder.Header = App.Text("WorkingCopy.AddToGitIgnore.InSameFolder");
|
||||
byParentFolder.IsVisible = !isRooted;
|
||||
byParentFolder.Click += (_, e) =>
|
||||
{
|
||||
var dir = Path.GetDirectoryName(change.Path)!.Replace('\\', '/').TrimEnd('/');
|
||||
Commands.GitIgnore.Add(_repo.FullPath, dir + "/");
|
||||
e.Handled = true;
|
||||
};
|
||||
addToIgnore.Items.Add(byParentFolder);
|
||||
|
||||
if (!string.IsNullOrEmpty(extension))
|
||||
{
|
||||
var byExtension = new MenuItem();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue