diff options
author | Luka Markušić <luka.markusic@microblink.com> | 2023-02-07 13:10:55 +0100 |
---|---|---|
committer | Luka Markušić <luka.markusic@microblink.com> | 2023-02-09 11:56:12 +0100 |
commit | 8af59c3e6e20b186d9a36220d09e3b9489881686 (patch) | |
tree | 18483b2c3cf8c66d3527243acea77ca1a6f0dc8c | |
parent | c713d19383f21b1a9bc87a38b3606c44cdd398b6 (diff) |
Copy remote branch name to clipboard
-rw-r--r-- | docs/keybindings/Keybindings_en.md | 1 | ||||
-rw-r--r-- | docs/keybindings/Keybindings_ja.md | 1 | ||||
-rw-r--r-- | docs/keybindings/Keybindings_ko.md | 1 | ||||
-rw-r--r-- | docs/keybindings/Keybindings_nl.md | 1 | ||||
-rw-r--r-- | docs/keybindings/Keybindings_pl.md | 1 | ||||
-rw-r--r-- | docs/keybindings/Keybindings_zh.md | 1 | ||||
-rw-r--r-- | pkg/gui/keybindings.go | 6 |
7 files changed, 12 insertions, 0 deletions
diff --git a/docs/keybindings/Keybindings_en.md b/docs/keybindings/Keybindings_en.md index 7c6e48e43..565698bf8 100644 --- a/docs/keybindings/Keybindings_en.md +++ b/docs/keybindings/Keybindings_en.md @@ -214,6 +214,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct ## Remote Branches <pre> + <kbd>ctrl+o</kbd>: copy branch name to clipboard <kbd>space</kbd>: checkout <kbd>n</kbd>: new branch <kbd>M</kbd>: merge into currently checked out branch diff --git a/docs/keybindings/Keybindings_ja.md b/docs/keybindings/Keybindings_ja.md index 6a9f67b6c..e8de2ca3c 100644 --- a/docs/keybindings/Keybindings_ja.md +++ b/docs/keybindings/Keybindings_ja.md @@ -268,6 +268,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct ## リモートブランチ <pre> + <kbd>ctrl+o</kbd>: ブランチ名をクリップボードにコピー <kbd>space</kbd>: チェックアウト <kbd>n</kbd>: 新しいブランチを作成 <kbd>M</kbd>: 現在のブランチにマージ diff --git a/docs/keybindings/Keybindings_ko.md b/docs/keybindings/Keybindings_ko.md index 151f49129..9eea1d343 100644 --- a/docs/keybindings/Keybindings_ko.md +++ b/docs/keybindings/Keybindings_ko.md @@ -199,6 +199,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct ## 원격 브랜치 <pre> + <kbd>ctrl+o</kbd>: 브랜치명을 클립보드에 복사 <kbd>space</kbd>: 체크아웃 <kbd>n</kbd>: 새 브랜치 생성 <kbd>M</kbd>: 현재 브랜치에 병합 diff --git a/docs/keybindings/Keybindings_nl.md b/docs/keybindings/Keybindings_nl.md index bdb6b20f7..b1e3a83b9 100644 --- a/docs/keybindings/Keybindings_nl.md +++ b/docs/keybindings/Keybindings_nl.md @@ -193,6 +193,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct ## Remote Branches <pre> + <kbd>ctrl+o</kbd>: kopieer branch name naar klembord <kbd>space</kbd>: uitchecken <kbd>n</kbd>: nieuwe branch <kbd>M</kbd>: merge in met huidige checked out branch diff --git a/docs/keybindings/Keybindings_pl.md b/docs/keybindings/Keybindings_pl.md index 9f00b4cc0..232034173 100644 --- a/docs/keybindings/Keybindings_pl.md +++ b/docs/keybindings/Keybindings_pl.md @@ -191,6 +191,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct ## Remote Branches <pre> + <kbd>ctrl+o</kbd>: copy branch name to clipboard <kbd>space</kbd>: przełącz <kbd>n</kbd>: nowa gałąź <kbd>M</kbd>: scal do obecnej gałęzi diff --git a/docs/keybindings/Keybindings_zh.md b/docs/keybindings/Keybindings_zh.md index 9bc663783..029c82434 100644 --- a/docs/keybindings/Keybindings_zh.md +++ b/docs/keybindings/Keybindings_zh.md @@ -274,6 +274,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct ## 远程分支 <pre> + <kbd>ctrl+o</kbd>: 将分支名称复制到剪贴板 <kbd>space</kbd>: 检出 <kbd>n</kbd>: 新分支 <kbd>M</kbd>: 合并到当前检出的分支 diff --git a/pkg/gui/keybindings.go b/pkg/gui/keybindings.go index ce935b661..572fa4594 100644 --- a/pkg/gui/keybindings.go +++ b/pkg/gui/keybindings.go @@ -212,6 +212,12 @@ func (self *Gui) GetInitialKeybindings() ([]*types.Binding, []*gocui.ViewMouseBi Description: self.c.Tr.LcCopyBranchNameToClipboard, }, { + ViewName: "remoteBranches", + Key: opts.GetKey(opts.Config.Universal.CopyToClipboard), + Handler: self.handleCopySelectedSideContextItemToClipboard, + Description: self.c.Tr.LcCopyBranchNameToClipboard, + }, + { ViewName: "commits", Key: opts.GetKey(opts.Config.Universal.CopyToClipboard), Handler: self.handleCopySelectedSideContextItemToClipboard, |