add fish config
This commit is contained in:
parent
51490fee54
commit
5c79902f4e
2 changed files with 42 additions and 0 deletions
22
fish/.config/fish/config.fish
Normal file
22
fish/.config/fish/config.fish
Normal file
|
@ -0,0 +1,22 @@
|
|||
## PATH
|
||||
|
||||
set -x PATH $PATH ~/.local/bin ~/.go/bin
|
||||
set -x EDITOR nano
|
||||
|
||||
## Go utils
|
||||
|
||||
set -x GOPATH ~/.go
|
||||
|
||||
|
||||
function bind_bang
|
||||
switch (commandline -t)[-1]
|
||||
case "!"
|
||||
commandline -t $history[1]; commandline -f repaint
|
||||
case "*"
|
||||
commandline -i !
|
||||
end
|
||||
end
|
||||
|
||||
function fish_user_key_bindings
|
||||
bind ! bind_bang
|
||||
end
|
20
fish/.config/fish/functions/email.fish
Normal file
20
fish/.config/fish/functions/email.fish
Normal file
|
@ -0,0 +1,20 @@
|
|||
function email --description 'Opens mutt with a specific account (waarp|perso)'
|
||||
set account waarp
|
||||
set usage 'Opens mutt with a specific account (waarp|perso)'
|
||||
|
||||
if test (count $argv) -gt 0
|
||||
switch $argv[1]
|
||||
case -h --help
|
||||
echo $usage
|
||||
return
|
||||
case waarp perso bcarlin
|
||||
set account $argv[1]
|
||||
case '*'
|
||||
echo "Bad account!"
|
||||
echo $usage
|
||||
return
|
||||
end
|
||||
end
|
||||
|
||||
env EMAIL_ACCOUNT=$account mutt
|
||||
end
|
Loading…
Add table
Reference in a new issue