mirror of
https://github.com/jesseduffield/lazygit.git
synced 2026-11-06 13:00:59 -04:00
Offer the bisect menu in more views than the commits panel
To start a bisect, users often know that one branch or tag is good and
another one is bad. The bisect menu was available in the commits panel
only, though. To mark the head of another branch, the user had to check
it out first, or find its head commit in the commits panel. The commits
panel shows only the checked-out branch.
Offer the menu in the local branches, remote branches, tags, sub-commits
and reflog views too. There it marks the selected item as good or bad,
and its entries name the item ("branch 'dev'", "tag 'v1.0'"), so that
it's clear what they act on. Once git knows both a good and a bad
commit, the bisect continues in the commits panel. It shows the good and
bad commits and the one to test next, and its menu acts on that one. So
focus the commits panel when a mark in another view gives git the second
of the two, and disable the key in the other views from then on. They
don't offer skipping either.
Name the selected commit "commit <hash>" in the commits panel's menu
too, so that it reads the same in all views.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
308a11f84d
commit
e1336f03dd
@@ -175,6 +175,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy branch name to clipboard | |
|
||||
| `` b `` | View bisect options | |
|
||||
| `` i `` | Show git-flow options | |
|
||||
| `` <space> `` | Checkout | Checkout selected item. |
|
||||
| `` n `` | New branch | |
|
||||
@@ -257,6 +258,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | View bisect options | |
|
||||
| `` <space> `` | Checkout | Checkout the selected commit as a detached HEAD. |
|
||||
| `` y `` | Copy commit attribute to clipboard | Copy commit attribute to clipboard (e.g. hash, URL, diff, message, author). |
|
||||
| `` o `` | Open commit in browser | |
|
||||
@@ -287,6 +289,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| `` s `` | Sort order | |
|
||||
| `` g `` | Reset | View reset options (soft/mixed/hard) for resetting onto selected item. |
|
||||
| `` <ctrl+t> `` | Open external diff tool (git difftool) | |
|
||||
| `` b `` | View bisect options | |
|
||||
| `` 0 `` | Focus main view | |
|
||||
| `` <enter> `` | View commits | |
|
||||
| `` / `` | Filter the current view by text | |
|
||||
@@ -358,6 +361,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | View bisect options | |
|
||||
| `` <space> `` | Checkout | Checkout the selected commit as a detached HEAD. |
|
||||
| `` y `` | Copy commit attribute to clipboard | Copy commit attribute to clipboard (e.g. hash, URL, diff, message, author). |
|
||||
| `` o `` | Open commit in browser | |
|
||||
@@ -392,6 +396,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy tag to clipboard | |
|
||||
| `` b `` | View bisect options | |
|
||||
| `` <space> `` | Checkout | Checkout the selected tag as a detached HEAD. |
|
||||
| `` n `` | New tag | Create new tag from current commit. You'll be prompted to enter a tag name and optional description. |
|
||||
| `` w `` | New worktree | |
|
||||
|
||||
@@ -134,6 +134,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | bisectオプションを表示 | |
|
||||
| `` <space> `` | チェックアウト(ブランチの切り替え) | 選択したコミットをデタッチドヘッド(特定のブランチに属さない状態)としてチェックアウトします。 |
|
||||
| `` y `` | コミット属性をクリップボードにコピー | コミット属性をクリップボードにコピーします(例:ハッシュ、URL、差分、メッセージ、作者)。 |
|
||||
| `` o `` | ブラウザでコミットを開く | |
|
||||
@@ -218,6 +219,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | タグをクリップボードにコピー | |
|
||||
| `` b `` | bisectオプションを表示 | |
|
||||
| `` <space> `` | チェックアウト(ブランチの切り替え) | 選択したタグをデタッチドHEADとしてチェックアウトします。 |
|
||||
| `` n `` | 新しいタグを作成 | 現在のコミットから新しいタグを作成します。タグ名とオプションの説明を入力するよう促されます。 |
|
||||
| `` w `` | 新しいワークツリー | |
|
||||
@@ -318,6 +320,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | bisectオプションを表示 | |
|
||||
| `` <space> `` | チェックアウト(ブランチの切り替え) | 選択したコミットをデタッチドヘッド(特定のブランチに属さない状態)としてチェックアウトします。 |
|
||||
| `` y `` | コミット属性をクリップボードにコピー | コミット属性をクリップボードにコピーします(例:ハッシュ、URL、差分、メッセージ、作者)。 |
|
||||
| `` o `` | ブラウザでコミットを開く | |
|
||||
@@ -360,6 +363,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| `` s `` | 並び順 | |
|
||||
| `` g `` | リセット | 選択した項目へのリセットオプション(ソフト/ミックス/ハード)を表示します。各リセットタイプの詳細は次の通りです:<br>- ソフトリセット:変更を保持し、ステージされた状態にします<br>- ミックスリセット:変更を保持し、ステージされていない状態にします<br>- ハードリセット:すべての変更を破棄します |
|
||||
| `` <ctrl+t> `` | 外部差分ツールを開く(git difftool) | |
|
||||
| `` b `` | bisectオプションを表示 | |
|
||||
| `` 0 `` | メインビューにフォーカス | |
|
||||
| `` <enter> `` | コミットを表示 | |
|
||||
| `` / `` | 現在のビューをテキストでフィルタリング | |
|
||||
@@ -369,6 +373,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | ブランチ名をクリップボードにコピー | |
|
||||
| `` b `` | bisectオプションを表示 | |
|
||||
| `` i `` | git-flowオプションを表示 | |
|
||||
| `` <space> `` | チェックアウト(ブランチの切り替え) | 選択した項目をチェックアウトします。 |
|
||||
| `` n `` | 新しいブランチ | |
|
||||
|
||||
@@ -65,6 +65,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | Bisect 옵션 보기 | |
|
||||
| `` <space> `` | 체크아웃 | Checkout the selected commit as a detached HEAD. |
|
||||
| `` y `` | 커밋 attribute 복사 | Copy commit attribute to clipboard (e.g. hash, URL, diff, message, author). |
|
||||
| `` o `` | 브라우저에서 커밋 열기 | |
|
||||
@@ -124,6 +125,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | Bisect 옵션 보기 | |
|
||||
| `` <space> `` | 체크아웃 | Checkout the selected commit as a detached HEAD. |
|
||||
| `` y `` | 커밋 attribute 복사 | Copy commit attribute to clipboard (e.g. hash, URL, diff, message, author). |
|
||||
| `` o `` | 브라우저에서 커밋 열기 | |
|
||||
@@ -205,6 +207,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | 브랜치명을 클립보드에 복사 | |
|
||||
| `` b `` | Bisect 옵션 보기 | |
|
||||
| `` i `` | Git-flow 옵션 보기 | |
|
||||
| `` <space> `` | 체크아웃 | Checkout selected item. |
|
||||
| `` n `` | 새 브랜치 생성 | |
|
||||
@@ -283,6 +286,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| `` s `` | Sort order | |
|
||||
| `` g `` | View reset options | View reset options (soft/mixed/hard) for resetting onto selected item. |
|
||||
| `` <ctrl+t> `` | Open external diff tool (git difftool) | |
|
||||
| `` b `` | Bisect 옵션 보기 | |
|
||||
| `` 0 `` | Focus main view | |
|
||||
| `` <enter> `` | 커밋 보기 | |
|
||||
| `` / `` | Filter the current view by text | |
|
||||
@@ -361,6 +365,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy tag to clipboard | |
|
||||
| `` b `` | Bisect 옵션 보기 | |
|
||||
| `` <space> `` | 체크아웃 | Checkout the selected tag as a detached HEAD. |
|
||||
| `` n `` | 태그를 생성 | Create new tag from current commit. You'll be prompted to enter a tag name and optional description. |
|
||||
| `` w `` | New worktree | |
|
||||
|
||||
@@ -99,6 +99,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Kopieer branch name naar klembord | |
|
||||
| `` b `` | View bisect options | |
|
||||
| `` i `` | Laat git-flow opties zien | |
|
||||
| `` <space> `` | Uitchecken | Geselecteerd item uitchecken. |
|
||||
| `` n `` | Nieuwe branch | |
|
||||
@@ -257,6 +258,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | View bisect options | |
|
||||
| `` <space> `` | Uitchecken | Check de geselecteerde branch uit als een detached HEAD. |
|
||||
| `` y `` | Copy commit attribute to clipboard | Copy commit attribute to clipboard (e.g. hash, URL, diff, message, author). |
|
||||
| `` o `` | Open commit in browser | |
|
||||
@@ -287,6 +289,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| `` s `` | Sort order | |
|
||||
| `` g `` | Bekijk reset opties | View reset options (soft/mixed/hard) for resetting onto selected item. |
|
||||
| `` <ctrl+t> `` | Open externe diff applicatie (git difftool) | |
|
||||
| `` b `` | View bisect options | |
|
||||
| `` 0 `` | Focus main view | |
|
||||
| `` <enter> `` | Bekijk commits | |
|
||||
| `` / `` | Filter the current view by text | |
|
||||
@@ -358,6 +361,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | View bisect options | |
|
||||
| `` <space> `` | Uitchecken | Check de geselecteerde branch uit als een detached HEAD. |
|
||||
| `` y `` | Copy commit attribute to clipboard | Copy commit attribute to clipboard (e.g. hash, URL, diff, message, author). |
|
||||
| `` o `` | Open commit in browser | |
|
||||
@@ -392,6 +396,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy tag to clipboard | |
|
||||
| `` b `` | View bisect options | |
|
||||
| `` <space> `` | Uitchecken | Geselecteerde tag uitchecken als detached HEAD. |
|
||||
| `` n `` | Creëer tag | Maak een nieuwe tag die naar de huidige commit wijst. Je wordt gevraagd om een tag naam en optionele beschrijving. |
|
||||
| `` w `` | New worktree | |
|
||||
|
||||
@@ -135,6 +135,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | Zobacz opcje bisect | |
|
||||
| `` <space> `` | Przełącz | Przełącz wybrany commit jako odłączoną HEAD. |
|
||||
| `` y `` | Kopiuj atrybut commita do schowka | Kopiuj atrybut commita do schowka (np. hash, URL, różnice, wiadomość, autor). |
|
||||
| `` o `` | Otwórz commit w przeglądarce | |
|
||||
@@ -162,6 +163,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Kopiuj nazwę gałęzi do schowka | |
|
||||
| `` b `` | Zobacz opcje bisect | |
|
||||
| `` i `` | Pokaż opcje git-flow | |
|
||||
| `` <space> `` | Przełącz | Przełącz wybrany element. |
|
||||
| `` n `` | Nowa gałąź | |
|
||||
@@ -337,6 +339,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | Zobacz opcje bisect | |
|
||||
| `` <space> `` | Przełącz | Przełącz wybrany commit jako odłączoną HEAD. |
|
||||
| `` y `` | Kopiuj atrybut commita do schowka | Kopiuj atrybut commita do schowka (np. hash, URL, różnice, wiadomość, autor). |
|
||||
| `` o `` | Otwórz commit w przeglądarce | |
|
||||
@@ -371,6 +374,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Skopiuj tag do schowka | |
|
||||
| `` b `` | Zobacz opcje bisect | |
|
||||
| `` <space> `` | Przełącz | Przełącz wybrany tag jako odłączoną głowę (detached HEAD). |
|
||||
| `` n `` | Nowy tag | Utwórz nowy tag z bieżącego commita. Zostaniesz poproszony o wprowadzenie nazwy tagu i opcjonalnego opisu. |
|
||||
| `` w `` | Nowe drzewo pracy | |
|
||||
@@ -409,6 +413,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| `` s `` | Kolejność sortowania | |
|
||||
| `` g `` | Reset | Wyświetl opcje resetu (miękki/mieszany/twardy) do wybranego elementu. |
|
||||
| `` <ctrl+t> `` | Otwórz zewnętrzne narzędzie różnic (git difftool) | |
|
||||
| `` b `` | Zobacz opcje bisect | |
|
||||
| `` 0 `` | Focus main view | |
|
||||
| `` <enter> `` | Pokaż commity | |
|
||||
| `` / `` | Filtruj bieżący widok po tekście | |
|
||||
|
||||
@@ -91,6 +91,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copiar nome da branch para área de transferência | |
|
||||
| `` b `` | Ver opções de bissecção | |
|
||||
| `` i `` | Exibir opções do git-flow | |
|
||||
| `` <space> `` | Verificar | Checar item selecionado |
|
||||
| `` n `` | Nova branch | |
|
||||
@@ -132,6 +133,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| `` s `` | Sort order | |
|
||||
| `` g `` | Restaurar | Ver opções de redefinição (soft/mixed/hard) para redefinir para o item selecionado. |
|
||||
| `` <ctrl+t> `` | Abrir ferramenta de diff externa (git difftool) | |
|
||||
| `` b `` | Ver opções de bissecção | |
|
||||
| `` 0 `` | Focar visualização principal | |
|
||||
| `` <enter> `` | Ver commits | |
|
||||
| `` / `` | Filtrar a visualização atual por texto | |
|
||||
@@ -203,6 +205,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copiar etiqueta para área de transferência | |
|
||||
| `` b `` | Ver opções de bissecção | |
|
||||
| `` <space> `` | Verificar | Checar a tag selecionada como um HEAD, desanexado |
|
||||
| `` n `` | Nova etiqueta | Crie uma nova etiqueta a partir do commit atual. Você será solicitado a digitar um nome e uma descrição opcional. |
|
||||
| `` w `` | Nova árvore de trabalho | |
|
||||
@@ -285,6 +288,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | Ver opções de bissecção | |
|
||||
| `` <space> `` | Verificar | Checkout the selected commit as a detached HEAD. |
|
||||
| `` y `` | Copy commit attribute to clipboard | Copy commit attribute to clipboard (e.g. hash, URL, diff, message, author). |
|
||||
| `` o `` | Abrir commit no navegador | |
|
||||
@@ -367,6 +371,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | Ver opções de bissecção | |
|
||||
| `` <space> `` | Verificar | Checkout the selected commit as a detached HEAD. |
|
||||
| `` y `` | Copy commit attribute to clipboard | Copy commit attribute to clipboard (e.g. hash, URL, diff, message, author). |
|
||||
| `` o `` | Abrir commit no navegador | |
|
||||
|
||||
@@ -143,6 +143,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | Просмотреть параметры бинарного поиска | |
|
||||
| `` <space> `` | Переключить | Checkout the selected commit as a detached HEAD. |
|
||||
| `` y `` | Скопировать атрибут коммита | Copy commit attribute to clipboard (e.g. hash, URL, diff, message, author). |
|
||||
| `` o `` | Открыть коммит в браузере | |
|
||||
@@ -205,6 +206,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Скопировать название ветки в буфер обмена | |
|
||||
| `` b `` | Просмотреть параметры бинарного поиска | |
|
||||
| `` i `` | Показать параметры git-flow | |
|
||||
| `` <space> `` | Переключить | Checkout selected item. |
|
||||
| `` n `` | Новая ветка | |
|
||||
@@ -252,6 +254,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy abbreviated commit hash to clipboard | |
|
||||
| `` b `` | Просмотреть параметры бинарного поиска | |
|
||||
| `` <space> `` | Переключить | Checkout the selected commit as a detached HEAD. |
|
||||
| `` y `` | Скопировать атрибут коммита | Copy commit attribute to clipboard (e.g. hash, URL, diff, message, author). |
|
||||
| `` o `` | Открыть коммит в браузере | |
|
||||
@@ -324,6 +327,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | Copy tag to clipboard | |
|
||||
| `` b `` | Просмотреть параметры бинарного поиска | |
|
||||
| `` <space> `` | Переключить | Checkout the selected tag as a detached HEAD. |
|
||||
| `` n `` | Создать тег | Create new tag from current commit. You'll be prompted to enter a tag name and optional description. |
|
||||
| `` w `` | New worktree | |
|
||||
@@ -350,6 +354,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| `` s `` | Порядок сортировки | |
|
||||
| `` g `` | Просмотреть параметры сброса | View reset options (soft/mixed/hard) for resetting onto selected item. |
|
||||
| `` <ctrl+t> `` | Open external diff tool (git difftool) | |
|
||||
| `` b `` | Просмотреть параметры бинарного поиска | |
|
||||
| `` 0 `` | Focus main view | |
|
||||
| `` <enter> `` | Просмотреть коммиты | |
|
||||
| `` / `` | Filter the current view by text | |
|
||||
|
||||
@@ -58,6 +58,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | 复制缩略提交哈希值到剪贴板 | |
|
||||
| `` b `` | 查看二分查找选项 | |
|
||||
| `` <space> `` | 检出 | 检出所选择的提交作为分离HEAD。 |
|
||||
| `` y `` | 复制提交属性到剪贴板 | 复制提交属性到剪贴板(如hash、URL、diff、消息、作者)。 |
|
||||
| `` o `` | 在浏览器中打开提交 | |
|
||||
@@ -102,6 +103,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | 复制缩略提交哈希值到剪贴板 | |
|
||||
| `` b `` | 查看二分查找选项 | |
|
||||
| `` <space> `` | 检出 | 检出所选择的提交作为分离HEAD。 |
|
||||
| `` y `` | 复制提交属性到剪贴板 | 复制提交属性到剪贴板(如hash、URL、diff、消息、作者)。 |
|
||||
| `` o `` | 在浏览器中打开提交 | |
|
||||
@@ -224,6 +226,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | 复制分支名称到剪贴板 | |
|
||||
| `` b `` | 查看二分查找选项 | |
|
||||
| `` i `` | 显示 git-flow 选项 | |
|
||||
| `` <space> `` | 检出 | 检出选中的项目 |
|
||||
| `` n `` | 新分支 | |
|
||||
@@ -255,6 +258,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | 复制标签到剪贴板 | |
|
||||
| `` b `` | 查看二分查找选项 | |
|
||||
| `` <space> `` | 检出 | 检出选择的标签作为分离的HEAD |
|
||||
| `` n `` | 创建标签 | 基于当前提交创建一个新标签。您将在弹窗中输入标签名称和描述(可选)。 |
|
||||
| `` w `` | 新建工作树 | |
|
||||
@@ -409,6 +413,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| `` s `` | 排序 | |
|
||||
| `` g `` | 查看重置选项 | 查看重置选项 (soft/mixed/hard) 用于重置到选择项 |
|
||||
| `` <ctrl+t> `` | 使用外部差异比较工具(git difftool) | |
|
||||
| `` b `` | 查看二分查找选项 | |
|
||||
| `` 0 `` | 聚焦主视图 | |
|
||||
| `` <enter> `` | 查看提交 | |
|
||||
| `` / `` | 通过文本过滤当前视图 | |
|
||||
|
||||
@@ -109,6 +109,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | 複製縮略提交雜湊值到剪貼簿 | |
|
||||
| `` b `` | 查看二分選項 | |
|
||||
| `` <space> `` | 檢出 | 檢出所選擇的提交作為分離HEAD。 |
|
||||
| `` y `` | 複製提交屬性 | 複製提交屬性到剪貼簿(如hash、URL、diff、訊息、作者)。 |
|
||||
| `` o `` | 在瀏覽器中開啟提交 | |
|
||||
@@ -236,6 +237,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | 複製縮略提交雜湊值到剪貼簿 | |
|
||||
| `` b `` | 查看二分選項 | |
|
||||
| `` <space> `` | 檢出 | 檢出所選擇的提交作為分離HEAD。 |
|
||||
| `` y `` | 複製提交屬性 | 複製提交屬性到剪貼簿(如hash、URL、diff、訊息、作者)。 |
|
||||
| `` o `` | 在瀏覽器中開啟提交 | |
|
||||
@@ -256,6 +258,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | 複製分支名稱到剪貼簿 | |
|
||||
| `` b `` | 查看二分選項 | |
|
||||
| `` i `` | 顯示 git-flow 選項 | |
|
||||
| `` <space> `` | 檢出 | 檢出選定的項目。 |
|
||||
| `` n `` | 新分支 | |
|
||||
@@ -287,6 +290,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| Key | Action | Info |
|
||||
|-----|--------|-------------|
|
||||
| `` <ctrl+o> `` | 複製標籤到剪貼簿 | |
|
||||
| `` b `` | 查看二分選項 | |
|
||||
| `` <space> `` | 檢出 | 檢出選擇的標籤作為分離的HEAD。 |
|
||||
| `` n `` | 建立標籤 | 基於目前提交建立一個新標籤。您將在彈窗中輸入標籤名稱和描述(可選)。 |
|
||||
| `` w `` | 新建工作樹 | |
|
||||
@@ -409,6 +413,7 @@ _This file is auto-generated. To update, make the changes in the pkg/i18n direct
|
||||
| `` s `` | 排序規則 | |
|
||||
| `` g `` | 檢視重設選項 | 檢視重置選項 (soft/mixed/hard) 用於重置到選擇項。 |
|
||||
| `` <ctrl+t> `` | 開啟外部差異工具 (git difftool) | |
|
||||
| `` b `` | 查看二分選項 | |
|
||||
| `` 0 `` | 聚焦主檢視 | |
|
||||
| `` <enter> `` | 檢視提交 | |
|
||||
| `` / `` | 搜尋 | |
|
||||
|
||||
+11
-3
@@ -146,8 +146,6 @@ func (gui *Gui) resetHelpersAndControllers() {
|
||||
|
||||
submodulesController := controllers.NewSubmodulesController(common)
|
||||
|
||||
bisectController := controllers.NewBisectController(common, gui.State.Contexts.LocalCommits)
|
||||
|
||||
commitMessageController := controllers.NewCommitMessageController(
|
||||
common,
|
||||
)
|
||||
@@ -311,9 +309,19 @@ func (gui *Gui) resetHelpersAndControllers() {
|
||||
|
||||
controllers.AttachControllers(gui.State.Contexts.LocalCommits,
|
||||
localCommitsController,
|
||||
bisectController,
|
||||
)
|
||||
|
||||
for _, context := range []controllers.CanBisect{
|
||||
gui.State.Contexts.LocalCommits,
|
||||
gui.State.Contexts.SubCommits,
|
||||
gui.State.Contexts.ReflogCommits,
|
||||
gui.State.Contexts.Branches,
|
||||
gui.State.Contexts.RemoteBranches,
|
||||
gui.State.Contexts.Tags,
|
||||
} {
|
||||
controllers.AttachControllers(context, controllers.NewBisectController(common, context))
|
||||
}
|
||||
|
||||
controllers.AttachControllers(gui.State.Contexts.CommitFiles,
|
||||
commitFilesController,
|
||||
)
|
||||
|
||||
@@ -6,6 +6,7 @@ import (
|
||||
|
||||
"github.com/jesseduffield/lazygit/pkg/commands/git_commands"
|
||||
"github.com/jesseduffield/lazygit/pkg/commands/models"
|
||||
"github.com/jesseduffield/lazygit/pkg/gui/context"
|
||||
"github.com/jesseduffield/lazygit/pkg/gui/types"
|
||||
"github.com/jesseduffield/lazygit/pkg/utils"
|
||||
)
|
||||
@@ -15,10 +16,15 @@ type CanBisect interface {
|
||||
GetSelectedRef() models.Ref
|
||||
}
|
||||
|
||||
// Offers the bisect menu for the selected item. The commits panel is where the
|
||||
// user bisects: it shows the good, bad and skipped commits, and the one to test
|
||||
// next. The other views only offer marking their selected item as good or bad,
|
||||
// until git knows both a good and a bad commit.
|
||||
type BisectController struct {
|
||||
baseController
|
||||
*ListControllerTrait[models.Ref]
|
||||
c *ControllerCommon
|
||||
c *ControllerCommon
|
||||
context CanBisect
|
||||
}
|
||||
|
||||
var _ types.IController = &BisectController{}
|
||||
@@ -30,6 +36,7 @@ func NewBisectController(
|
||||
return &BisectController{
|
||||
baseController: baseController{},
|
||||
c: c,
|
||||
context: context,
|
||||
ListControllerTrait: NewListControllerTrait(
|
||||
c,
|
||||
context,
|
||||
@@ -44,16 +51,29 @@ func NewBisectController(
|
||||
func (self *BisectController) GetKeybindings(opts types.KeybindingsOpts) []*types.Binding {
|
||||
bindings := []*types.Binding{
|
||||
{
|
||||
Keys: opts.GetKeys(opts.Config.Commits.ViewBisectOptions),
|
||||
Handler: opts.Guards.OutsideFilterMode(self.withItem(self.openMenu)),
|
||||
Description: self.c.Tr.ViewBisectOptions,
|
||||
OpensMenu: true,
|
||||
Keys: opts.GetKeys(opts.Config.Commits.ViewBisectOptions),
|
||||
Handler: opts.Guards.OutsideFilterMode(self.withItem(self.openMenu)),
|
||||
GetDisabledReason: self.notBisectingOutsideCommitsPanel,
|
||||
Description: self.c.Tr.ViewBisectOptions,
|
||||
OpensMenu: true,
|
||||
},
|
||||
}
|
||||
|
||||
return bindings
|
||||
}
|
||||
|
||||
func (self *BisectController) isCommitsPanel() bool {
|
||||
return self.context.GetKey() == context.LOCAL_COMMITS_CONTEXT_KEY
|
||||
}
|
||||
|
||||
func (self *BisectController) notBisectingOutsideCommitsPanel() *types.DisabledReason {
|
||||
if !self.isCommitsPanel() && self.c.Model().BisectInfo.Bisecting() {
|
||||
return &types.DisabledReason{Text: self.c.Tr.Bisect.UseCommitsPanel}
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func (self *BisectController) openMenu(ref models.Ref) error {
|
||||
// no shame in getting this directly rather than using the cached value
|
||||
// given how cheap it is to obtain
|
||||
@@ -77,16 +97,20 @@ func (self *BisectController) openMenuBeforeBisecting(info *git_commands.BisectI
|
||||
map[string]string{"ref": refDescription, "term": term})
|
||||
}
|
||||
|
||||
menuItems := []*types.MenuItem{
|
||||
self.markMenuItem(markLabel(info.NewTerm()), ref.FullRefName(), info.NewTerm(), disabledReason, 'b'),
|
||||
self.markMenuItem(markLabel(info.OldTerm()), ref.FullRefName(), info.OldTerm(), disabledReason, 'g'),
|
||||
}
|
||||
if self.isCommitsPanel() {
|
||||
menuItems = append(menuItems, self.skipMenuItem(
|
||||
utils.ResolvePlaceholderString(self.c.Tr.Bisect.SkipRef, map[string]string{"ref": refDescription}),
|
||||
ref.FullRefName(), types.KeepCommitSelectionByHash, disabledReason, 's'))
|
||||
}
|
||||
menuItems = append(menuItems, self.resetMenuItem())
|
||||
|
||||
return self.c.Menu(types.CreateMenuOptions{
|
||||
Title: self.c.Tr.Bisect.BisectMenuTitle,
|
||||
Items: []*types.MenuItem{
|
||||
self.markMenuItem(markLabel(info.NewTerm()), ref.FullRefName(), info.NewTerm(), disabledReason, 'b'),
|
||||
self.markMenuItem(markLabel(info.OldTerm()), ref.FullRefName(), info.OldTerm(), disabledReason, 'g'),
|
||||
self.skipMenuItem(
|
||||
utils.ResolvePlaceholderString(self.c.Tr.Bisect.SkipRef, map[string]string{"ref": refDescription}),
|
||||
ref.FullRefName(), types.KeepCommitSelectionByHash, disabledReason, 's'),
|
||||
self.resetMenuItem(),
|
||||
},
|
||||
Items: menuItems,
|
||||
})
|
||||
}
|
||||
|
||||
@@ -128,6 +152,21 @@ func (self *BisectController) openMidBisectMenu(info *git_commands.BisectInfo, r
|
||||
|
||||
// Returns how the bisect menu refers to the given item.
|
||||
func (self *BisectController) describeRef(ref models.Ref) string {
|
||||
switch ref := ref.(type) {
|
||||
case *models.Branch:
|
||||
// The branches view shows a detached head as a branch, too
|
||||
if !ref.DetachedHead {
|
||||
return utils.ResolvePlaceholderString(self.c.Tr.Bisect.BranchRef,
|
||||
map[string]string{"name": ref.RefName()})
|
||||
}
|
||||
case *models.RemoteBranch:
|
||||
return utils.ResolvePlaceholderString(self.c.Tr.Bisect.BranchRef,
|
||||
map[string]string{"name": ref.RefName()})
|
||||
case *models.Tag:
|
||||
return utils.ResolvePlaceholderString(self.c.Tr.Bisect.TagRef,
|
||||
map[string]string{"name": ref.RefName()})
|
||||
}
|
||||
|
||||
return utils.ResolvePlaceholderString(self.c.Tr.Bisect.CommitRef,
|
||||
map[string]string{"hash": utils.ShortHash(ref.FullRefName())})
|
||||
}
|
||||
@@ -141,6 +180,12 @@ func (self *BisectController) markMenuItem(label string, ref string, term string
|
||||
return err
|
||||
}
|
||||
|
||||
if !self.isCommitsPanel() && self.c.Git().Bisect.GetInfo().Bisecting() {
|
||||
// Git knows both a good and a bad commit now, so the user goes
|
||||
// on in the commits panel
|
||||
self.c.Context().Push(self.c.Contexts().LocalCommits, types.OnFocusOpts{})
|
||||
}
|
||||
|
||||
return self.afterMark(types.KeepCommitSelectionByHash)
|
||||
},
|
||||
DisabledReason: disabledReason,
|
||||
@@ -175,11 +220,17 @@ func (self *BisectController) resetMenuItem() *types.MenuItem {
|
||||
}
|
||||
|
||||
func (self *BisectController) openStartBisectMenu(info *git_commands.BisectInfo, ref models.Ref) error {
|
||||
refDescription := self.describeRef(ref)
|
||||
markLabel := func(term string) string {
|
||||
return utils.ResolvePlaceholderString(self.c.Tr.Bisect.MarkRefStart,
|
||||
map[string]string{"ref": refDescription, "term": term})
|
||||
}
|
||||
|
||||
return self.c.Menu(types.CreateMenuOptions{
|
||||
Title: self.c.Tr.Bisect.BisectMenuTitle,
|
||||
Items: []*types.MenuItem{
|
||||
{
|
||||
Label: fmt.Sprintf(self.c.Tr.Bisect.MarkStart, utils.ShortHash(ref.FullRefName()), info.NewTerm()),
|
||||
Label: markLabel(info.NewTerm()),
|
||||
OnPress: func() error {
|
||||
self.c.LogAction(self.c.Tr.Actions.StartBisect)
|
||||
if err := self.c.Git().Bisect.Start(); err != nil {
|
||||
@@ -197,7 +248,7 @@ func (self *BisectController) openStartBisectMenu(info *git_commands.BisectInfo,
|
||||
Keys: menuKey('b'),
|
||||
},
|
||||
{
|
||||
Label: fmt.Sprintf(self.c.Tr.Bisect.MarkStart, utils.ShortHash(ref.FullRefName()), info.OldTerm()),
|
||||
Label: markLabel(info.OldTerm()),
|
||||
OnPress: func() error {
|
||||
self.c.LogAction(self.c.Tr.Actions.StartBisect)
|
||||
if err := self.c.Git().Bisect.Start(); err != nil {
|
||||
|
||||
+8
-2
@@ -1039,7 +1039,7 @@ type TranslationSet struct {
|
||||
}
|
||||
|
||||
type Bisect struct {
|
||||
MarkStart string
|
||||
MarkRefStart string
|
||||
ResetTitle string
|
||||
ResetPrompt string
|
||||
ResetOption string
|
||||
@@ -1053,6 +1053,9 @@ type Bisect struct {
|
||||
SkipSelected string
|
||||
SkipRef string
|
||||
CommitRef string
|
||||
BranchRef string
|
||||
TagRef string
|
||||
UseCommitsPanel string
|
||||
CompleteTitle string
|
||||
CompletePrompt string
|
||||
CompletePromptIndeterminate string
|
||||
@@ -2374,12 +2377,15 @@ func EnglishTranslationSet() *TranslationSet {
|
||||
},
|
||||
Bisect: Bisect{
|
||||
Mark: "Mark current commit (%s) as %s",
|
||||
MarkStart: "Mark %s as %s (start bisect)",
|
||||
MarkRefStart: "Mark {{.ref}} as {{.term}} (start bisect)",
|
||||
SkipCurrent: "Skip current commit (%s)",
|
||||
SkipSelected: "Skip selected commit (%s)",
|
||||
MarkRef: "Mark {{.ref}} as {{.term}}",
|
||||
SkipRef: "Skip {{.ref}}",
|
||||
CommitRef: "commit {{.hash}}",
|
||||
BranchRef: "branch '{{.name}}'",
|
||||
TagRef: "tag '{{.name}}'",
|
||||
UseCommitsPanel: "Bisecting is in progress; use the commits panel",
|
||||
ResetTitle: "Reset 'git bisect'",
|
||||
ResetPrompt: "Are you sure you want to reset 'git bisect'?",
|
||||
ResetOption: "Reset bisect",
|
||||
|
||||
@@ -0,0 +1,77 @@
|
||||
package bisect
|
||||
|
||||
import (
|
||||
"github.com/jesseduffield/lazygit/pkg/config"
|
||||
. "github.com/jesseduffield/lazygit/pkg/integration/components"
|
||||
)
|
||||
|
||||
var StartFromBranches = NewIntegrationTest(NewIntegrationTestArgs{
|
||||
Description: "Start a bisect by marking the heads of two branches as good and bad in the branches panel",
|
||||
ExtraCmdArgs: []string{},
|
||||
Skip: false,
|
||||
SetupRepo: func(shell *Shell) {
|
||||
shell.
|
||||
CreateNCommits(3).
|
||||
NewBranch("feature").
|
||||
CreateNCommitsStartingAt(6, 4).
|
||||
Checkout("master")
|
||||
},
|
||||
SetupConfig: func(cfg *config.AppConfig) {
|
||||
cfg.GetUserConfig().Git.Log.ShowGraph = "never"
|
||||
},
|
||||
Run: func(t *TestDriver, keys config.KeybindingConfig) {
|
||||
t.Views().Branches().
|
||||
Focus().
|
||||
Lines(
|
||||
Contains("master").IsSelected(),
|
||||
Contains("feature"),
|
||||
).
|
||||
Press(keys.Commits.ViewBisectOptions).
|
||||
Tap(func() {
|
||||
t.ExpectPopup().Menu().Title(Equals("Bisect")).
|
||||
Lines(
|
||||
Contains("b Mark branch 'master' as bad (start bisect)"),
|
||||
Contains("g Mark branch 'master' as good (start bisect)"),
|
||||
Contains("t Choose bisect terms"),
|
||||
Contains("Cancel"),
|
||||
).
|
||||
Select(Contains("as good")).Confirm()
|
||||
|
||||
t.Views().Information().Content(Contains("Bisecting"))
|
||||
}).
|
||||
NavigateToLine(Contains("feature")).
|
||||
Press(keys.Commits.ViewBisectOptions).
|
||||
Tap(func() {
|
||||
t.ExpectPopup().Menu().Title(Equals("Bisect")).
|
||||
Lines(
|
||||
Contains("b Mark branch 'feature' as bad"),
|
||||
Contains("g Mark branch 'feature' as good"),
|
||||
Contains("r Reset bisect"),
|
||||
Contains("Cancel"),
|
||||
).
|
||||
Select(Contains("as bad")).Confirm()
|
||||
})
|
||||
|
||||
t.Views().Commits().
|
||||
IsFocused().
|
||||
Lines(
|
||||
Contains("CI commit-09").Contains("<-- bad"),
|
||||
Contains("CI commit-08"),
|
||||
Contains("CI commit-07"),
|
||||
Contains("CI commit-06").Contains("<-- current").IsSelected(),
|
||||
Contains("CI commit-05"),
|
||||
Contains("CI commit-04"),
|
||||
Contains("CI commit-03").Contains("<-- good"),
|
||||
Contains("CI commit-02"),
|
||||
Contains("CI commit-01"),
|
||||
)
|
||||
|
||||
// Once git knows both a good and a bad commit, the bisect continues in
|
||||
// the commits panel
|
||||
t.Views().Branches().
|
||||
Focus().
|
||||
Press(keys.Commits.ViewBisectOptions)
|
||||
|
||||
t.ExpectToast(Equals("Disabled: Bisecting is in progress; use the commits panel"))
|
||||
},
|
||||
})
|
||||
@@ -0,0 +1,70 @@
|
||||
package bisect
|
||||
|
||||
import (
|
||||
"github.com/jesseduffield/lazygit/pkg/config"
|
||||
. "github.com/jesseduffield/lazygit/pkg/integration/components"
|
||||
)
|
||||
|
||||
var StartFromSubCommitsAndReflog = NewIntegrationTest(NewIntegrationTestArgs{
|
||||
Description: "Start a bisect by marking a commit of a branch as bad and a reflog entry as good",
|
||||
ExtraCmdArgs: []string{},
|
||||
Skip: false,
|
||||
SetupRepo: func(shell *Shell) {
|
||||
shell.
|
||||
CreateNCommits(3).
|
||||
NewBranch("feature").
|
||||
CreateNCommitsStartingAt(3, 4).
|
||||
Checkout("master")
|
||||
},
|
||||
SetupConfig: func(cfg *config.AppConfig) {
|
||||
cfg.GetUserConfig().Git.Log.ShowGraph = "never"
|
||||
},
|
||||
Run: func(t *TestDriver, keys config.KeybindingConfig) {
|
||||
t.Views().Branches().
|
||||
Focus().
|
||||
NavigateToLine(Contains("feature")).
|
||||
PressEnter()
|
||||
|
||||
t.Views().SubCommits().
|
||||
IsFocused().
|
||||
SelectedLine(Contains("CI commit-06")).
|
||||
Press(keys.Commits.ViewBisectOptions).
|
||||
Tap(func() {
|
||||
t.ExpectPopup().Menu().Title(Equals("Bisect")).
|
||||
Lines(
|
||||
MatchesRegexp(`b Mark commit [0-9a-f]+ as bad \(start bisect\)`),
|
||||
MatchesRegexp(`g Mark commit [0-9a-f]+ as good \(start bisect\)`),
|
||||
Contains("t Choose bisect terms"),
|
||||
Contains("Cancel"),
|
||||
).
|
||||
Select(Contains("as bad")).Confirm()
|
||||
}).
|
||||
PressEscape()
|
||||
|
||||
t.Views().ReflogCommits().
|
||||
Focus().
|
||||
NavigateToLine(Contains("commit-01")).
|
||||
Press(keys.Commits.ViewBisectOptions).
|
||||
Tap(func() {
|
||||
t.ExpectPopup().Menu().Title(Equals("Bisect")).
|
||||
Lines(
|
||||
MatchesRegexp(`b Mark commit [0-9a-f]+ as bad`),
|
||||
MatchesRegexp(`g Mark commit [0-9a-f]+ as good`),
|
||||
Contains("r Reset bisect"),
|
||||
Contains("Cancel"),
|
||||
).
|
||||
Select(Contains("as good")).Confirm()
|
||||
})
|
||||
|
||||
t.Views().Commits().
|
||||
IsFocused().
|
||||
Lines(
|
||||
Contains("CI commit-06").Contains("<-- bad"),
|
||||
Contains("CI commit-05"),
|
||||
Contains("CI commit-04"),
|
||||
Contains("CI commit-03").Contains("<-- current").IsSelected(),
|
||||
Contains("CI commit-02"),
|
||||
Contains("CI commit-01").Contains("<-- good"),
|
||||
)
|
||||
},
|
||||
})
|
||||
@@ -0,0 +1,76 @@
|
||||
package bisect
|
||||
|
||||
import (
|
||||
"github.com/jesseduffield/lazygit/pkg/config"
|
||||
. "github.com/jesseduffield/lazygit/pkg/integration/components"
|
||||
)
|
||||
|
||||
var StartFromTagsAndRemoteBranches = NewIntegrationTest(NewIntegrationTestArgs{
|
||||
Description: "Start a bisect by marking a tag as good and a remote branch as bad",
|
||||
ExtraCmdArgs: []string{},
|
||||
Skip: false,
|
||||
SetupRepo: func(shell *Shell) {
|
||||
shell.
|
||||
CreateNCommits(2).
|
||||
CreateLightweightTag("v1.0", "HEAD").
|
||||
CreateNCommitsStartingAt(4, 3).
|
||||
CloneIntoRemote("origin").
|
||||
HardReset("HEAD~2")
|
||||
},
|
||||
SetupConfig: func(cfg *config.AppConfig) {
|
||||
cfg.GetUserConfig().Git.Log.ShowGraph = "never"
|
||||
},
|
||||
Run: func(t *TestDriver, keys config.KeybindingConfig) {
|
||||
t.Views().Tags().
|
||||
Focus().
|
||||
Lines(
|
||||
Contains("v1.0").IsSelected(),
|
||||
).
|
||||
Press(keys.Commits.ViewBisectOptions).
|
||||
Tap(func() {
|
||||
t.ExpectPopup().Menu().Title(Equals("Bisect")).
|
||||
Lines(
|
||||
Contains("b Mark tag 'v1.0' as bad (start bisect)"),
|
||||
Contains("g Mark tag 'v1.0' as good (start bisect)"),
|
||||
Contains("t Choose bisect terms"),
|
||||
Contains("Cancel"),
|
||||
).
|
||||
Select(Contains("as good")).Confirm()
|
||||
})
|
||||
|
||||
t.Views().Remotes().
|
||||
Focus().
|
||||
Lines(
|
||||
Contains("origin").IsSelected(),
|
||||
).
|
||||
PressEnter()
|
||||
|
||||
t.Views().RemoteBranches().
|
||||
IsFocused().
|
||||
Lines(
|
||||
Contains("master").IsSelected(),
|
||||
).
|
||||
Press(keys.Commits.ViewBisectOptions).
|
||||
Tap(func() {
|
||||
t.ExpectPopup().Menu().Title(Equals("Bisect")).
|
||||
Lines(
|
||||
Contains("b Mark branch 'origin/master' as bad"),
|
||||
Contains("g Mark branch 'origin/master' as good"),
|
||||
Contains("r Reset bisect"),
|
||||
Contains("Cancel"),
|
||||
).
|
||||
Select(Contains("as bad")).Confirm()
|
||||
})
|
||||
|
||||
t.Views().Commits().
|
||||
IsFocused().
|
||||
Lines(
|
||||
Contains("CI commit-06").Contains("<-- bad"),
|
||||
Contains("CI commit-05"),
|
||||
Contains("CI commit-04").Contains("<-- current").IsSelected(),
|
||||
Contains("CI commit-03"),
|
||||
Contains("CI v1.0 commit-02").Contains("<-- good"),
|
||||
Contains("CI commit-01"),
|
||||
)
|
||||
},
|
||||
})
|
||||
@@ -42,6 +42,9 @@ var tests = []*components.IntegrationTest{
|
||||
bisect.SelectCurrentCommit,
|
||||
bisect.SelectCurrentCommitInLongRange,
|
||||
bisect.Skip,
|
||||
bisect.StartFromBranches,
|
||||
bisect.StartFromSubCommitsAndReflog,
|
||||
bisect.StartFromTagsAndRemoteBranches,
|
||||
branch.CheckoutAutostash,
|
||||
branch.CheckoutByName,
|
||||
branch.CheckoutPreviousBranch,
|
||||
|
||||
Reference in New Issue
Block a user