Skip to content

Commit 6abdf32

Browse files
committed
fix: remove --push option because it is not valid parameter for git-flow-next (sourcegit-scm#2269)
Signed-off-by: leo <longshuang@msn.cn>
1 parent 460cc68 commit 6abdf32

File tree

4 files changed

+3
-17
lines changed

4 files changed

+3
-17
lines changed

src/Commands/GitFlow.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ public static async Task<bool> StartAsync(string repo, Models.GitFlowBranchType
4949
return await start.Use(log).ExecAsync().ConfigureAwait(false);
5050
}
5151

52-
public static async Task<bool> FinishAsync(string repo, Models.GitFlowBranchType type, string name, bool squash, bool push, bool keepBranch, Models.ICommandLog log)
52+
public static async Task<bool> FinishAsync(string repo, Models.GitFlowBranchType type, string name, bool squash, bool keepBranch, Models.ICommandLog log)
5353
{
5454
var builder = new StringBuilder();
5555
builder.Append("flow ");
@@ -73,8 +73,6 @@ public static async Task<bool> FinishAsync(string repo, Models.GitFlowBranchType
7373
builder.Append(" finish ");
7474
if (squash)
7575
builder.Append("--squash ");
76-
if (push)
77-
builder.Append("--push ");
7876
if (keepBranch)
7977
builder.Append("-k ");
8078
builder.Append(name);

src/Resources/Locales/en_US.axaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -436,7 +436,6 @@
436436
<x:String x:Key="Text.GitFlow.FinishHotfix" xml:space="preserve">FLOW - Finish Hotfix</x:String>
437437
<x:String x:Key="Text.GitFlow.FinishRelease" xml:space="preserve">FLOW - Finish Release</x:String>
438438
<x:String x:Key="Text.GitFlow.FinishTarget" xml:space="preserve">Target:</x:String>
439-
<x:String x:Key="Text.GitFlow.FinishWithPush" xml:space="preserve">Push to remote(s) after performing finish</x:String>
440439
<x:String x:Key="Text.GitFlow.FinishWithSquash" xml:space="preserve">Squash during merge</x:String>
441440
<x:String x:Key="Text.GitFlow.Hotfix" xml:space="preserve">Hotfix:</x:String>
442441
<x:String x:Key="Text.GitFlow.HotfixPrefix" xml:space="preserve">Hotfix Prefix:</x:String>

src/ViewModels/GitFlowFinish.cs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,6 @@ public bool Squash
2121
set;
2222
} = false;
2323

24-
public bool AutoPush
25-
{
26-
get;
27-
set;
28-
} = false;
29-
3024
public bool KeepBranch
3125
{
3226
get;
@@ -50,7 +44,7 @@ public override async Task<bool> Sure()
5044

5145
var prefix = _repo.GitFlow.GetPrefix(Type);
5246
var name = Branch.Name.StartsWith(prefix) ? Branch.Name.Substring(prefix.Length) : Branch.Name;
53-
var succ = await Commands.GitFlow.FinishAsync(_repo.FullPath, Type, name, Squash, AutoPush, KeepBranch, log);
47+
var succ = await Commands.GitFlow.FinishAsync(_repo.FullPath, Type, name, Squash, KeepBranch, log);
5448

5549
log.Complete();
5650
return succ;

src/Views/GitFlowFinish.axaml

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
IsVisible="{Binding Type, Converter={x:Static ObjectConverters.Equal}, ConverterParameter={x:Static m:GitFlowBranchType.Hotfix}}"/>
2828
</StackPanel>
2929

30-
<Grid Margin="0,16,0,0" RowDefinitions="32,32,32,32" ColumnDefinitions="150,*">
30+
<Grid Margin="0,16,0,0" RowDefinitions="32,32,32" ColumnDefinitions="150,*">
3131
<TextBlock Grid.Row="0" Grid.Column="0"
3232
HorizontalAlignment="Right" VerticalAlignment="Center"
3333
Margin="0,0,8,0"
@@ -43,11 +43,6 @@
4343
ToolTip.Tip="--squash"/>
4444

4545
<CheckBox Grid.Row="2" Grid.Column="1"
46-
Content="{DynamicResource Text.GitFlow.FinishWithPush}"
47-
IsChecked="{Binding AutoPush, Mode=TwoWay}"
48-
ToolTip.Tip="--push"/>
49-
50-
<CheckBox Grid.Row="3" Grid.Column="1"
5146
Content="{DynamicResource Text.GitFlow.KeepBranchAfterFinish}"
5247
IsChecked="{Binding KeepBranch, Mode=TwoWay}"
5348
ToolTip.Tip="-k"/>

0 commit comments

Comments
 (0)