mirror of
https://github.com/jesseduffield/lazygit.git
synced 2024-12-12 11:15:00 +02:00
remove clipboard option for now because we need a better way of doing it
This commit is contained in:
parent
fcf916d138
commit
ce20d1b482
@ -1,8 +1,6 @@
|
|||||||
package gui
|
package gui
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"strings"
|
|
||||||
|
|
||||||
"github.com/jesseduffield/gocui"
|
"github.com/jesseduffield/gocui"
|
||||||
"github.com/jesseduffield/lazygit/pkg/utils"
|
"github.com/jesseduffield/lazygit/pkg/utils"
|
||||||
)
|
)
|
||||||
@ -121,15 +119,3 @@ func (gui *Gui) secondaryPatchPanelUpdateOpts() *viewUpdateOpts {
|
|||||||
|
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (gui *Gui) handleCopyPatchToClipboard() error {
|
|
||||||
// TODO: test that this works
|
|
||||||
|
|
||||||
if err := gui.OSCommand.CopyToClipboard(
|
|
||||||
strings.Join(gui.GitCommand.PatchManager.RenderEachFilePatch(true), "\n"),
|
|
||||||
); err != nil {
|
|
||||||
return gui.surfaceError(err)
|
|
||||||
}
|
|
||||||
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
@ -13,8 +13,8 @@ func (gui *Gui) handleCreatePatchOptionsMenu(g *gocui.Gui, v *gocui.View) error
|
|||||||
|
|
||||||
menuItems := []*menuItem{
|
menuItems := []*menuItem{
|
||||||
{
|
{
|
||||||
displayString: "copy patch to clipboard",
|
displayString: "reset patch",
|
||||||
onPress: gui.handleCopyPatchToClipboard,
|
onPress: gui.handleResetPatch,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
displayString: "apply patch",
|
displayString: "apply patch",
|
||||||
@ -24,10 +24,6 @@ func (gui *Gui) handleCreatePatchOptionsMenu(g *gocui.Gui, v *gocui.View) error
|
|||||||
displayString: "apply patch in reverse",
|
displayString: "apply patch in reverse",
|
||||||
onPress: func() error { return gui.handleApplyPatch(true) },
|
onPress: func() error { return gui.handleApplyPatch(true) },
|
||||||
},
|
},
|
||||||
{
|
|
||||||
displayString: "reset patch",
|
|
||||||
onPress: gui.handleResetPatch,
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if gui.GitCommand.PatchManager.CanRebase {
|
if gui.GitCommand.PatchManager.CanRebase {
|
||||||
|
Loading…
Reference in New Issue
Block a user