mirror of
https://github.com/donovanglover/nix-config.git
synced 2024-11-23 00:34:24 +01:00
Add base fish config, managed with stow
This commit is contained in:
parent
c0b2905abf
commit
65e0ed690a
22
stow/fish/.config/fish/config.fish
Normal file
22
stow/fish/.config/fish/config.fish
Normal file
@ -0,0 +1,22 @@
|
||||
#set -U fish_greeting ""
|
||||
#set -U fish_history ""
|
||||
#set -U fish_user_paths
|
||||
#set -U BROWSER "waterfox"
|
||||
|
||||
fish_vi_key_bindings
|
||||
|
||||
alias c="clear"
|
||||
alias cf="tput reset"
|
||||
alias pls="sudo"
|
||||
alias rm="rm -i"
|
||||
alias mkdir="mkdir -p"
|
||||
|
||||
alias exa="exa --group-directories-first"
|
||||
alias ls="exa"
|
||||
alias l="ls -l"
|
||||
alias lsa="ls -a"
|
||||
alias tree="exa --long --tree"
|
||||
alias t="tree -L 1"
|
||||
|
||||
alias todo="rg TODO"
|
||||
alias pwd="pwd | sed -e 's!$HOME!~!g'"
|
25
stow/fish/.config/fish/functions/fish_prompt.fish
Normal file
25
stow/fish/.config/fish/functions/fish_prompt.fish
Normal file
@ -0,0 +1,25 @@
|
||||
function fish_prompt
|
||||
set -l color_cwd
|
||||
set -l suffix
|
||||
set host (prompt_hostname)
|
||||
set pwd (basename $PWD)
|
||||
if [ $pwd = $USER ]
|
||||
set pwd "~"
|
||||
end
|
||||
switch "$USER"
|
||||
case root toor
|
||||
if set -q fish_color_cwd_root
|
||||
set color_cwd $fish_color_cwd_root
|
||||
else
|
||||
set color_cwd $fish_color_cwd
|
||||
end
|
||||
set suffix '#'
|
||||
case '*'
|
||||
set color_cwd $fish_color_cwd
|
||||
set suffix ""
|
||||
end
|
||||
|
||||
# $USER@$host
|
||||
echo -n "$pwd ➤➤➤ "
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user