From 91254440a13261e993a21cd1b08a8db9e52490bd Mon Sep 17 00:00:00 2001 From: Matthew Lemon Date: Tue, 11 Apr 2023 12:08:40 +0100 Subject: Enables completion in bash again This seemed to be missing from my moving back to bash. --- bashrc | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'bashrc') diff --git a/bashrc b/bashrc index 621fd21..e70c824 100644 --- a/bashrc +++ b/bashrc @@ -4,6 +4,11 @@ complete -cf sudo man which # reduce history size export HISTCONTROL=ignoreboth +# completions +if [ -f /usr/share/bash-completion/completions/pass ]; then + . /usr/share/bash-completion/completions/pass +fi + # export PS1='bash-\v-\u@\h \W\$ ' export PS1='\[\033[38;5;208m\]\u@\h:\w\$\[\033[0m\] ' -- cgit v1.2.3 From 9ce59b1edd0c220607b4449bcac7b13363bc2e11 Mon Sep 17 00:00:00 2001 From: Matthew Lemon Date: Tue, 11 Apr 2023 12:09:32 +0100 Subject: Enable fzf in the bash shell again Some useful stuff in here. --- bashrc | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'bashrc') diff --git a/bashrc b/bashrc index e70c824..64226f9 100644 --- a/bashrc +++ b/bashrc @@ -27,6 +27,8 @@ export PATH=~/bin/:$PATH source $HOME/dotfiles/openai_key # aliases +alias pacget="pacman -Slq | fzf --multi --preview 'pacman -Si {1}' | xargs -ro sudo pacman -S" +alias pacdel="pacman -Qq | fzf --multi --preview 'pacman -Qi {1}' | xargs -ro sudo pacman -Rns" alias gloga='git log --oneline --decorate --graph --all' alias batnote='batnote-source-code' alias am='append_to_masterlist' @@ -52,11 +54,15 @@ export TERM="screen-256color" export LESS="-iMRS -x2" export NOTES_DIR="~/Documents/Notes" export RANGER_LOAD_DEFAULT_RC="FALSE" -export FZF_DEFAULT_COMMAND="ag --nocolor -g " +export FZF_DEFAULT_COMMAND="rg --files --hidden --glob '!.git' " export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND" export FZF_ALT_C_COMMAND="$FZF_DEFAULT_COMMAND" export FZF_DEFAULT_OPTS="--color info:108,prompt:109,spinner:108,pointer:168,marker:168" +# fzf +source /usr/share/fzf/key-bindings.bash +source /usr/share/fzf/completion.bash + # gpg export=GPG_TTY="$(tty)" export=SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)" -- cgit v1.2.3