diff --git a/tabby-core/src/components/appRoot.component.ts b/tabby-core/src/components/appRoot.component.ts index 5cbccf1319..30e338f3ef 100644 --- a/tabby-core/src/components/appRoot.component.ts +++ b/tabby-core/src/components/appRoot.component.ts @@ -112,6 +112,10 @@ export class AppRootComponent { if (hotkey === 'duplicate-tab') { this.app.duplicateTab(this.app.activeTab) } + if (hotkey === 'restart-tab') { + this.app.duplicateTab(this.app.activeTab) + this.app.closeTab(this.app.activeTab, true) + } if (hotkey === 'explode-tab' && this.app.activeTab instanceof SplitTabComponent) { this.app.explodeTab(this.app.activeTab) } diff --git a/tabby-core/src/configDefaults.linux.yaml b/tabby-core/src/configDefaults.linux.yaml index cadb416099..4805ce0e73 100644 --- a/tabby-core/src/configDefaults.linux.yaml +++ b/tabby-core/src/configDefaults.linux.yaml @@ -21,6 +21,7 @@ hotkeys: rearrange-panes: - 'Ctrl-Shift' duplicate-tab: [] + restart-tab: [] explode-tab: - 'Ctrl-Shift-.' combine-tabs: diff --git a/tabby-core/src/configDefaults.macos.yaml b/tabby-core/src/configDefaults.macos.yaml index 620471dffb..b1be9458fb 100644 --- a/tabby-core/src/configDefaults.macos.yaml +++ b/tabby-core/src/configDefaults.macos.yaml @@ -39,6 +39,7 @@ hotkeys: tab-10: - '⌘-0' duplicate-tab: [] + restart-tab: [] explode-tab: - '⌘-Shift-.' combine-tabs: diff --git a/tabby-core/src/configDefaults.windows.yaml b/tabby-core/src/configDefaults.windows.yaml index 19293b8793..80bd85ee5e 100644 --- a/tabby-core/src/configDefaults.windows.yaml +++ b/tabby-core/src/configDefaults.windows.yaml @@ -22,6 +22,7 @@ hotkeys: rearrange-panes: - 'Ctrl-Shift' duplicate-tab: [] + restart-tab: [] explode-tab: - 'Ctrl-Shift-.' combine-tabs: diff --git a/tabby-core/src/hotkeys.ts b/tabby-core/src/hotkeys.ts index e35f662f34..c6c15403f0 100644 --- a/tabby-core/src/hotkeys.ts +++ b/tabby-core/src/hotkeys.ts @@ -56,6 +56,10 @@ export class AppHotkeyProvider extends HotkeyProvider { id: 'duplicate-tab', name: this.translate.instant('Duplicate tab'), }, + { + id: 'restart-tab', + name: this.translate.instant('Restart tab'), + }, { id: 'explode-tab', name: this.translate.instant('Turn current tab\'s panes into separate tabs'),