nushell: add complete attribute (#13310)

Added correct attribute so nushell can generate completions for ghostty
redefined commands (i.e., `ssh` and `sudo`).

Fixes #12008
This commit is contained in:
Jon Parise
2026-07-12 21:03:20 -04:00
committed by GitHub

View File

@@ -6,6 +6,7 @@ export module ghostty {
# Wrap `ssh` with `ghostty +ssh` and translate the shell-integration
# feature flags into command options.
@complete external
export def --wrapped ssh [...args] {
if not ((has_feature "ssh-env") or (has_feature "ssh-terminfo")) {
^ssh ...$args
@@ -24,6 +25,7 @@ export module ghostty {
}
# Wrap `sudo` to preserve Ghostty's TERMINFO environment variable
@complete external
export def --wrapped sudo [...args] {
mut sudo_args = $args