diff options
author | Luka Markušić <luka.markusic@microblink.com> | 2022-04-08 17:06:07 +0200 |
---|---|---|
committer | Luka Markušić <luka.markusic@microblink.com> | 2022-04-11 14:04:06 +0200 |
commit | f83308c8df529e5a50332ff68a7e7c5106cea414 (patch) | |
tree | acf77d42f80e4be852f8cd386a2abccc0585da29 /pkg/gui/controllers.go | |
parent | d0e099d2fc306206dac8fee2b8d88d8e178c3ed6 (diff) |
Add option to (un)set upstream for a local branch
Diffstat (limited to 'pkg/gui/controllers.go')
-rw-r--r-- | pkg/gui/controllers.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/pkg/gui/controllers.go b/pkg/gui/controllers.go index 4987210c9..2c851739d 100644 --- a/pkg/gui/controllers.go +++ b/pkg/gui/controllers.go @@ -23,12 +23,13 @@ func (gui *Gui) resetControllers() { ) rebaseHelper := helpers.NewMergeAndRebaseHelper(helperCommon, gui.State.Contexts, gui.git, gui.takeOverMergeConflictScrolling, refsHelper) + suggestionsHelper := helpers.NewSuggestionsHelper(helperCommon, model, gui.refreshSuggestions) gui.helpers = &helpers.Helpers{ Refs: refsHelper, Host: helpers.NewHostHelper(helperCommon, gui.git), PatchBuilding: helpers.NewPatchBuildingHelper(helperCommon, gui.git), Bisect: helpers.NewBisectHelper(helperCommon, gui.git), - Suggestions: helpers.NewSuggestionsHelper(helperCommon, model, gui.refreshSuggestions), + Suggestions: suggestionsHelper, Files: helpers.NewFilesHelper(helperCommon, gui.git, osCommand), WorkingTree: helpers.NewWorkingTreeHelper(helperCommon, gui.git, model), Tags: helpers.NewTagsHelper(helperCommon, gui.git), @@ -41,6 +42,7 @@ func (gui *Gui) resetControllers() { func() *cherrypicking.CherryPicking { return gui.State.Modes.CherryPicking }, rebaseHelper, ), + Upstream: helpers.NewUpstreamHelper(helperCommon, model, suggestionsHelper.GetRemoteBranchesSuggestionsFunc), } gui.CustomCommandsClient = custom_commands.NewClient( @@ -64,7 +66,6 @@ func (gui *Gui) resetControllers() { syncController := controllers.NewSyncController( common, - gui.getSuggestedRemote, ) submodulesController := controllers.NewSubmodulesController( |