terminal: Add carapace completions to all shells

Bash, nushell and zsh all make use of carapace completions by default.
This commit is contained in:
Marty Oehme 2025-09-04 22:59:39 +02:00
parent e44baaf207
commit 4b65069436
Signed by: Marty
GPG key ID: 4E535BC19C61886E
4 changed files with 12 additions and 0 deletions

View file

@ -28,6 +28,8 @@ alias ls='ls --color=auto'
eval "$(starship init bash)"
eval "$(zoxide init bash)"
export CARAPACE_BRIDGES='zsh,fish,bash,inshellisense' # optional
source <(carapace _carapace)
set -o vi
stty time 0

View file

@ -35,6 +35,9 @@ starship init nu | save -f ($nu.data-dir | path join "vendor/autoload/starship.n
atuin init nu | save -f ($nu.data-dir | path join "vendor/autoload/atuin.nu")
# load zoxide bookmarks
zoxide init nushell | save -f ($nu.data-dir | path join "vendor/autoload/zoxide.nu")
# load carapace completions
source ~/.cache/carapace/init.nu
# keybinds
$env.config.keybindings = [

View file

@ -16,3 +16,8 @@
#
# You can remove these comments if you want or leave
# them for future reference.
## create carapace completions
$env.CARAPACE_BRIDGES = 'zsh,fish,bash,inshellisense' # optional
mkdir ~/.cache/carapace
carapace _carapace nushell | save --force ~/.cache/carapace/init.nu

View file

@ -126,6 +126,8 @@ setopt autocd
eval "$(starship init zsh)"
eval "$(zoxide init zsh)"
eval "$(atuin init zsh)"
export CARAPACE_BRIDGES='zsh,fish,bash,inshellisense' # optional
source <(carapace _carapace)
# Speed up autocomplete, force prefix mapping
zstyle ':completion:*' accept-exact '*(N)'