diff --git a/toolboxes/bluefin-cli/files/etc/bashrc b/toolboxes/bluefin-cli/files/etc/bashrc index 5e95f6e..31e1248 100644 --- a/toolboxes/bluefin-cli/files/etc/bashrc +++ b/toolboxes/bluefin-cli/files/etc/bashrc @@ -1,3 +1,4 @@ +# shellcheck shell=bash disable=SC1091 # /etc/bashrc # System wide functions and aliases @@ -47,7 +48,11 @@ if [ -z "$BASHRCSOURCED" ]; then fi STARSHIP_CONFIG=/etc/starship.toml export STARSHIP_CONFIG - eval "$(starship init $SHELL)" + eval "$(starship init bash)" + + # Enable fzf keybindings + [ -r /run/host/usr/share/fzf/shell/key-bindings.bash ] && \ + . /run/host/usr/share/fzf/shell/key-bindings.bash # Enable atuin and bash-prexec source /usr/share/bash-prexec diff --git a/toolboxes/bluefin-cli/files/etc/profile.d/bash_completion.sh b/toolboxes/bluefin-cli/files/etc/profile.d/bash_completion.sh index f1fa970..910b484 100644 --- a/toolboxes/bluefin-cli/files/etc/profile.d/bash_completion.sh +++ b/toolboxes/bluefin-cli/files/etc/profile.d/bash_completion.sh @@ -7,16 +7,20 @@ if [ "x${BASH_VERSION-}" != x -a "x${PS1-}" != x -a "x${BASH_COMPLETION_VERSINFO [ "${BASH_VERSINFO[0]}" -eq 4 -a "${BASH_VERSINFO[1]}" -ge 2 ]; then [ -r "${XDG_CONFIG_HOME:-$HOME/.config}/bash_completion" ] && . "${XDG_CONFIG_HOME:-$HOME/.config}/bash_completion" - if shopt -q progcomp && [ -r /usr/share/bash-completion/bash_completion ]; then - # Source completion code. - . /usr/share/bash-completion/bash_completion + if shopt -q progcomp && [ -d /usr/share/bash-completion/completions ]; then + for rc in /usr/share/bash-completion/completions/*; do + if test -r "$rc"; then + . "$rc" + fi + done + unset rc fi if shopt -q progcomp && [ -r /usr/local/share/bash-completion/bash_completion ]; then # Source completion code. . /usr/local/share/bash-completion/bash_completion fi if ! test -L /home/linuxbrew/.linuxbrew/etc/bash_completion.d/brew && test "$(id -u)" -gt 0; then - /home/linuxbrew/.linuxbrew/bin/brew completions link + /home/linuxbrew/.linuxbrew/bin/brew completions link > /dev/null fi if test -d /home/linuxbrew/.linuxbrew/etc/bash_completion.d; then for rc in /home/linuxbrew/.linuxbrew/etc/bash_completion.d/*; do @@ -26,5 +30,13 @@ if [ "x${BASH_VERSION-}" != x -a "x${PS1-}" != x -a "x${BASH_COMPLETION_VERSINFO done unset rc fi + if test -d /run/host/etc/bash_completion.d; then + for rc in /run/host/etc/bash_completion.d/*; do + if test -r "$rc"; then + . "$rc" + fi + done + unset rc + fi fi fi diff --git a/toolboxes/bluefin-cli/files/usr/share/fish/vendor_conf.d/bling.fish b/toolboxes/bluefin-cli/files/usr/share/fish/vendor_conf.d/bling.fish index 1e8ef53..34b6438 100644 --- a/toolboxes/bluefin-cli/files/usr/share/fish/vendor_conf.d/bling.fish +++ b/toolboxes/bluefin-cli/files/usr/share/fish/vendor_conf.d/bling.fish @@ -3,6 +3,7 @@ if status is-interactive eval "$(starship init fish)" eval "$(atuin init fish)" eval "$(zoxide init fish --cmd cd)" + set -gx HOST (hostname -s) end # Eza for ls diff --git a/toolboxes/bluefin-cli/files/usr/share/fish/vendor_functions.d/fish_title.fish b/toolboxes/bluefin-cli/files/usr/share/fish/vendor_functions.d/fish_title.fish new file mode 100644 index 0000000..f1e820a --- /dev/null +++ b/toolboxes/bluefin-cli/files/usr/share/fish/vendor_functions.d/fish_title.fish @@ -0,0 +1,4 @@ +function fish_title + set -q argv[1]; or set argv fish + echo "$USER@$HOST" (fish_prompt_pwd_dir_length=1 prompt_pwd): $argv +end \ No newline at end of file