Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ on:
- beta
- 'cto/**'
- 'nikita/**'
- 'repair/**'
workflow_dispatch:

concurrency:
Expand Down Expand Up @@ -95,7 +96,7 @@ jobs:

- name: Install build tools (Ubuntu)
if: runner.os == 'Linux'
run: sudo apt-get update && sudo apt-get install -y build-essential python3 make g++ ripgrep
run: sudo apt-get update && sudo apt-get install -y build-essential python3 make g++ ripgrep tmux

- name: Install dependencies
run: bun install --frozen-lockfile
Expand Down Expand Up @@ -131,14 +132,17 @@ jobs:
bun-version-file: package.json

- name: Install build tools (Ubuntu)
run: sudo apt-get update && sudo apt-get install -y build-essential python3 make g++ ripgrep
run: sudo apt-get update && sudo apt-get install -y build-essential python3 make g++ ripgrep tmux

- name: Install dependencies
run: bun install --frozen-lockfile

- name: Build CLI for terminal tests
run: bun run build

- name: Prepare pinned Zit for tmux isolation tests
run: node --input-type=module -e "import { installZit } from './scripts/install-zit.mjs'; await installZit({ force:true });"

- name: Run built terminal tests
run: bun run test:tuistory -- --shard=${{ matrix.shard }}/4

Expand All @@ -164,7 +168,7 @@ jobs:

- name: Install build tools (Ubuntu)
if: runner.os == 'Linux'
run: sudo apt-get update && sudo apt-get install -y build-essential python3 make g++ ripgrep
run: sudo apt-get update && sudo apt-get install -y build-essential python3 make g++ ripgrep tmux

- name: Install dependencies
run: bun install --frozen-lockfile
Expand Down
5 changes: 4 additions & 1 deletion .github/workflows/full-proof.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,16 @@ jobs:
bun-version-file: package.json

- name: Install native build tools
run: sudo apt-get update && sudo apt-get install -y build-essential python3 make g++ ripgrep
run: sudo apt-get update && sudo apt-get install -y build-essential python3 make g++ ripgrep tmux

- name: Install dependencies
run: bun install --frozen-lockfile

- name: Prepare built CLI fixtures
run: bun run build

- name: Prepare pinned Zit for tmux isolation tests
run: node --input-type=module -e "import { installZit } from './scripts/install-zit.mjs'; await installZit({ force:true });"

- name: Run complete proof
run: bun run proof
7 changes: 5 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ jobs:
bun-version-file: package.json

- name: Install ripgrep
run: sudo apt-get update && sudo apt-get install -y ripgrep
run: sudo apt-get update && sudo apt-get install -y ripgrep tmux

- name: Install dependencies
run: bun install --frozen-lockfile
Expand Down Expand Up @@ -240,14 +240,17 @@ jobs:
bun-version-file: package.json

- name: Install ripgrep
run: sudo apt-get update && sudo apt-get install -y ripgrep
run: sudo apt-get update && sudo apt-get install -y ripgrep tmux

- name: Install dependencies
run: bun install --frozen-lockfile

- name: Build CLI for terminal tests
run: bun run build

- name: Prepare pinned Zit for tmux isolation tests
run: node --input-type=module -e "import { installZit } from './scripts/install-zit.mjs'; await installZit({ force:true });"

- name: Run built terminal tests
run: bun run test:tuistory -- --shard=${{ matrix.shard }}/4

Expand Down
120 changes: 120 additions & 0 deletions .github/workflows/terminal-compatibility.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
name: Terminal compatibility

on:
pull_request:
paths:
- 'src/ui/**'
- 'src/testing/**'
- 'src/utils/tmux.ts'
- 'src/startup/cliOptions.ts'
- 'src/index.ts'
- 'package.json'
- 'bun.lock'
- 'tests/tuistory/*terminal*'
- 'tests/tuistory/*resize*'
- 'tests/tuistory/*tmux*'
- '.github/workflows/terminal-compatibility.yml'
workflow_dispatch:

permissions:
contents: read

concurrency:
group: terminal-compatibility-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
tmux:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 0
- uses: actions/setup-node@v7
with:
node-version: 24
package-manager-cache: false
- uses: oven-sh/setup-bun@v2
with:
bun-version-file: package.json
- run: sudo apt-get update && sudo apt-get install -y build-essential python3 ripgrep tmux
- run: bun install --frozen-lockfile
- run: bun run build
- name: Prepare pinned Zit for real isolation tests
run: node --input-type=module -e "import { installZit } from './scripts/install-zit.mjs'; await installZit({ force:true });"
- name: Test compiled startup and rapid resize through real tmux
run: bun run test:tuistory tests/tuistory/tmux-startup.tuistory.test.ts tests/tuistory/resize-flicker.tuistory.test.ts

native-macos:
runs-on: macos-26
timeout-minutes: 20
strategy:
fail-fast: false
matrix:
terminal: [iterm2, ghostty, cmux, vscode]
env:
AUTOHAND_NATIVE_TERMINAL: ${{ matrix.terminal }}
HOMEBREW_NO_AUTO_UPDATE: '1'
AUTOHAND_SKIP_COMPUTER_CONTROL_INSTALL: '1'
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 0
- uses: actions/setup-node@v7
with:
node-version: 24
package-manager-cache: false
- uses: oven-sh/setup-bun@v2
with:
bun-version-file: package.json
- name: Install native terminal and UI test build tools
shell: bash
run: |
set -euo pipefail
brew install xcodegen ripgrep tmux
case "$AUTOHAND_NATIVE_TERMINAL" in
iterm2) brew install --cask iterm2; terminal_app=/Applications/iTerm.app ;;
ghostty) brew install --cask ghostty; terminal_app=/Applications/Ghostty.app ;;
cmux) brew install --cask cmux; terminal_app=/Applications/cmux.app ;;
vscode) brew install --cask visual-studio-code; terminal_app='/Applications/Visual Studio Code.app' ;;
esac
codesign --verify --deep --strict "$terminal_app"
spctl --assess --type execute --verbose "$terminal_app"
# Approve only the verified app on this disposable VM for unattended launch.
xattr -dr com.apple.quarantine "$terminal_app"
/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -f "$terminal_app"
defaults read "$terminal_app/Contents/Info" CFBundleIdentifier
system_profiler SPDisplaysDataType
stat -f 'Console user: %Su' /dev/console
mkdir -p .artifacts/native-terminal
brew info --json=v2 --installed > .artifacts/native-terminal/installed-versions.json
# These preferences belong only to this disposable Actions VM.
defaults write com.googlecode.iterm2 EnableAPIServer -bool false
defaults write com.googlecode.iterm2 PromptOnQuit -bool false
defaults write com.googlecode.iterm2 SUEnableAutomaticChecks -bool false
defaults write com.googlecode.iterm2 NSQuitAlwaysKeepsWindows -bool false
defaults write com.googlecode.iterm2 ApplePersistenceIgnoreState -bool true
- run: bun install --frozen-lockfile
- run: bun run build
- name: Run Tuistory with native XCTest window and accessibility checks
run: bun run test:tuistory tests/tuistory/native-terminal.tuistory.test.ts
- name: Export native screen captures
if: always()
shell: bash
run: |
result=".artifacts/native-terminal/$AUTOHAND_NATIVE_TERMINAL/NativeTerminal.xcresult"
if [ -d "$result" ]; then
xcrun xcresulttool export attachments --path "$result" --output-path ".artifacts/native-terminal/$AUTOHAND_NATIVE_TERMINAL/screenshots"
fi
- name: Preserve native screenshots and XCTest results
if: always()
uses: actions/upload-artifact@v7
with:
name: native-terminal-${{ matrix.terminal }}
path: |
.artifacts/native-terminal/installed-versions.json
.artifacts/native-terminal/**/*.xcresult
.artifacts/native-terminal/**/screenshots
if-no-files-found: error
retention-days: 7
15 changes: 13 additions & 2 deletions docs/config-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -3092,7 +3092,7 @@ When a noninteractive task needs approval, it stops at the first missing authori
| Flag | Description |
| ----------------------------- | ---------------------------------------------------------------------------------------------- |
| `--worktree [name]` | Run session in isolated git worktree (optional worktree/branch name) |
| `--tmux` | Launch in a dedicated tmux session (implies `--worktree`; cannot be used with `--no-worktree`) |
| `--tmux` | Launch in a dedicated tmux session in the current directory; supports `--worktree` or `--zit` |
| `--zit [intent]` | Run session in a disposable Zit workspace, recorded as a Zit change on exit (optional intent) |
| `--no-worktree` | Disable git worktree isolation in auto-mode |
| `-c, --continue` | Resume the latest session in this folder, including with `-p`; start fresh when none exists |
Expand Down Expand Up @@ -3128,7 +3128,18 @@ What happens:

Inspect the result with `zit status` and `zit show <change>`; accepting the change into the current state is left to you (`zit accept`).

`--zit` cannot be combined with `--worktree`, `--tmux`, `--patch`, `--mode rpc|acp`, or a standalone `--auto-mode` loop.
`--zit` cannot be combined with `--worktree`, `--patch`, `--mode rpc|acp`, or a standalone `--auto-mode` loop.

`--tmux` uses the current directory by default, including directories outside Git repositories. Workspace isolation is optional:

```bash
autohand --tmux
autohand --tmux --worktree my-task
autohand --tmux --zit
```

Use `--worktree` or `--zit` when isolation is needed; `--tmux --no-worktree` is also supported.


### Auto-Mode

Expand Down
2 changes: 1 addition & 1 deletion docs/config-reference_cs.md
Original file line number Diff line number Diff line change
Expand Up @@ -1931,7 +1931,7 @@ Tyto příznaky přepisují nastavení konfiguračního souboru:
| Vlajka | Popis |
| ------------------------------ | ---------------------------------------------------------------------------------------------- |
| `--worktree [name]` | Spustit relaci v izolovaném pracovním stromu git (volitelný název pracovního stromu/větve) |
| `--tmux` | Spustit ve vyhrazené relaci tmux (předpokládá `--worktree`; nelze použít s `--no-worktree`) |
| `--tmux` | Spustit ve vyhrazené relaci tmux v aktuálním adresáři; podporuje `--worktree` nebo `--zit` |
| `--no-worktree` | Zakázat izolaci pracovního stromu git v automatickém režimu |
| `--auto-commit` | Automatické potvrzení změn po dokončení úkolů |
| `--patch` | Vygenerujte git patch bez použití změn |
Expand Down
2 changes: 1 addition & 1 deletion docs/config-reference_de.md
Original file line number Diff line number Diff line change
Expand Up @@ -2054,7 +2054,7 @@ Diese Flags überschreiben Konfigurationsdatei-Einstellungen:
| Flag | Beschreibung |
| ----------------------------- | ---------------------------------------------------------------------------------------------- |
| `--worktree [name]` | Sitzung in isoliertem Git-Worktree ausführen (optionaler Worktree-/Branch-Name) |
| `--tmux` | In dedizierter tmux-Sitzung starten (impliziert `--worktree`; kann nicht mit `--no-worktree` verwendet werden) |
| `--tmux` | In dedizierter tmux-Sitzung im aktuellen Verzeichnis starten; unterstützt `--worktree` oder `--zit` |
| `--no-worktree` | Git-Worktree-Isolierung im Auto-Modus deaktivieren |
| `--auto-commit` | Änderungen nach Abschluss der Aufgaben automatisch committen |
| `--patch` | Git-Patch generieren, ohne Änderungen anzuwenden |
Expand Down
2 changes: 1 addition & 1 deletion docs/config-reference_es.md
Original file line number Diff line number Diff line change
Expand Up @@ -1396,7 +1396,7 @@ Estos flags sobrescriben la configuración del archivo:
| `--model <modelo>` | Sobrescribir modelo |
| `--path <ruta>` | Sobrescribir raíz del espacio de trabajo |
| `--worktree [nombre]` | Ejecutar sesión en un git worktree aislado (nombre opcional de worktree/rama) |
| `--tmux` | Iniciar en una sesión tmux dedicada (implica `--worktree`; no se puede usar con `--no-worktree`) |
| `--tmux` | Iniciar una sesión tmux dedicada en el directorio actual; admite `--worktree` o `--zit` |
| `--add-dir <ruta>` | Agregar directorios adicionales al alcance del espacio de trabajo (se puede usar múltiples veces) |
| `--config <ruta>` | Usar archivo de configuración personalizado |
| `--temperature <n>` | Establecer temperatura (0-1) |
Expand Down
2 changes: 1 addition & 1 deletion docs/config-reference_fr.md
Original file line number Diff line number Diff line change
Expand Up @@ -1913,7 +1913,7 @@ Ces indicateurs remplacent les paramètres du fichier de configuration :
| Drapeau | Descriptif |
| ----------------------------- | ------------------------------------------------------------------------------------------------------------- |
| `--worktree [name]` | Exécuter la session dans un arbre de travail git isolé (nom de l'arbre de travail/de la branche facultatif) |
| `--tmux` | Lancer dans une session tmux dédiée (implique `--worktree` ; ne peut pas être utilisé avec `--no-worktree`) |
| `--tmux` | Lancer une session tmux dédiée dans le répertoire courant ; accepte `--worktree` ou `--zit` |
| `--no-worktree` | Désactiver l'isolation de git worktree en mode automatique |
| `--auto-commit` | Valider automatiquement les modifications après avoir terminé les tâches |
| `--patch` | Générer le patch git sans appliquer les modifications |
Expand Down
2 changes: 1 addition & 1 deletion docs/config-reference_hi.md
Original file line number Diff line number Diff line change
Expand Up @@ -1309,7 +1309,7 @@ Autohand `~/.autohand/` (या `$AUTOHAND_HOME`) में डेटा स्
| `--model <model>` | मॉडल ओवरराइड करें |
| `--path <path>` | वर्कस्पेस रूट ओवरराइड करें |
| `--worktree [name]` | सेशन को अलग git worktree में चलाएँ (वैकल्पिक worktree/branch नाम) |
| `--tmux` | समर्पित tmux सेशन में शुरू करें (`--worktree` निहित; `--no-worktree` के साथ उपयोग नहीं कर सकते) |
| `--tmux` | वर्तमान निर्देशिका में समर्पित tmux सेशन शुरू करें; `--worktree` या `--zit` समर्थित हैं |
| `--add-dir <path>` | वर्कस्पेस स्कोप में अतिरिक्त डायरेक्टरी जोड़ें (कई बार उपयोग किया जा सकता है) |
| `--config <path>` | कस्टम कॉन्फिग फाइल का उपयोग करें |
| `--temperature <n>` | टेम्परेचर सेट करें (0-1) |
Expand Down
2 changes: 1 addition & 1 deletion docs/config-reference_hu.md
Original file line number Diff line number Diff line change
Expand Up @@ -1913,7 +1913,7 @@ Ezek a jelzők felülírják a konfigurációs fájl beállításait:
| zászló | Leírás |
| ------------------------------ | ---------------------------------------------------------------------------------------------- |
| `--worktree [name]` | Munkamenet futtatása elszigetelt git-munkafán (opcionális munkafa/ág neve) |
| `--tmux` | Indítás egy dedikált tmux munkamenetben (az `--worktree`-t jelenti; nem használható a `--no-worktree` kóddal) |
| `--tmux` | Indítás dedikált tmux munkamenetben az aktuális könyvtárban; támogatja a `--worktree` és `--zit` kapcsolókat |
| `--no-worktree` | A git munkafa elkülönítésének letiltása automatikus módban |
| `--auto-commit` | Változások automatikus véglegesítése a feladatok elvégzése után |
| `--patch` | Git javítás generálása változtatások alkalmazása nélkül |
Expand Down
2 changes: 1 addition & 1 deletion docs/config-reference_id.md
Original file line number Diff line number Diff line change
Expand Up @@ -1367,7 +1367,7 @@ Flag-flag ini mengganti pengaturan file konfigurasi:
| `--model <model>` | Ganti model |
| `--path <path>` | Ganti root workspace |
| `--worktree [nama]` | Jalankan sesi di git worktree terisolasi (nama worktree/branch opsional) |
| `--tmux` | Jalankan dalam sesi tmux khusus (mengimplikasikan `--worktree`; tidak bisa dipakai dengan `--no-worktree`) |
| `--tmux` | Jalankan sesi tmux khusus di direktori saat ini; mendukung `--worktree` atau `--zit` |
| `--add-dir <path>` | Tambahkan direktori tambahan ke lingkup workspace (dapat digunakan beberapa kali) |
| `--config <path>` | Gunakan file konfigurasi kustom |
| `--temperature <n>` | Atur temperature (0-1) |
Expand Down
2 changes: 1 addition & 1 deletion docs/config-reference_it.md
Original file line number Diff line number Diff line change
Expand Up @@ -1913,7 +1913,7 @@ Questi flag sovrascrivono le impostazioni del file di configurazione:
| Bandiera | Descrizione |
| ----------------------- | ---------------------------------------------------------------------------------------- |
| `--worktree [name]` | Esegui la sessione in un albero di lavoro git isolato (nome albero di lavoro/ramo opzionale) |
| `--tmux` | Avvia in una sessione tmux dedicata (implica `--worktree`; non può essere utilizzato con `--no-worktree`) |
| `--tmux` | Avvia una sessione tmux dedicata nella directory corrente; supporta `--worktree` o `--zit` |
| `--no-worktree` | Disabilita l'isolamento di git worktree in modalità automatica |
| `--auto-commit` | Effettua il commit automatico delle modifiche dopo aver completato le attività |
| `--patch` | Genera patch git senza applicare modifiche |
Expand Down
2 changes: 1 addition & 1 deletion docs/config-reference_ja.md
Original file line number Diff line number Diff line change
Expand Up @@ -1361,7 +1361,7 @@ Autohandは `~/.autohand/`(または `$AUTOHAND_HOME`)にデータを保存
| `--model <model>` | モデルをオーバーライド |
| `--path <path>` | ワークスペースルートをオーバーライド |
| `--worktree [name]` | セッションを分離されたgit worktreeで実行(worktree/ブランチ名は任意) |
| `--tmux` | 専用のtmuxセッションで起動(`--worktree`を含意。`--no-worktree`とは併用不可) |
| `--tmux` | 現在のディレクトリで専用の tmux セッションを起動。`--worktree` または `--zit` に対応 |
| `--add-dir <path>` | ワークスペーススコープに追加ディレクトリを追加(複数回使用可能) |
| `--config <path>` | カスタム設定ファイルを使用 |
| `--temperature <n>` | 温度を設定(0-1) |
Expand Down
Loading
Loading