exa comme alias de ls + tambouille pour changer facilement d’éditeur par défaut + modif changement de VPN

This commit is contained in:
Benjamin VAUDOUR 2023-03-20 10:26:02 +01:00
parent 4fe246ed62
commit eca6cfba88
4 changed files with 58 additions and 15 deletions

View File

@ -6,9 +6,21 @@ fn -go-ls {|@argv|
e:go-ls --group-directories-first -T '+%Y.%m.%d %H:%M' --git $@argv
}
var cmd = $-go-ls~
fn -exa {|@argv|
e:exa --color auto --git --icons --group-directories-first $@argv
}
fn -exal {|@argv|
-exa -lghH@ --time-style long-iso $@argv
}
var cmd = $-exa~
var cmdl = $-exal~
edit:add-var ls~ {|@argv| $cmd $@argv }
edit:add-var la~ {|@argv| $cmd -a $@argv }
edit:add-var ll~ {|@argv| $cmd -lh $@argv }
edit:add-var lla~ {|@argv| $cmd -lha $@argv }
#edit:add-var la~ {|@argv| $cmd -a $@argv }
#edit:add-var ll~ {|@argv| $cmd -lh $@argv }
#edit:add-var lla~ {|@argv| $cmd -lha $@argv }
edit:add-var la~ {|@argv| $cmd -aa $@argv }
edit:add-var ll~ {|@argv| $cmdl -l $@argv }
edit:add-var lla~ {|@argv| $cmdl -aa $@argv }

View File

@ -1,7 +1,35 @@
var app = 'nvim'
var editors = [
&emac=[
&e={|@argv| e:emacs $@argv }
&v={|@argv| e:emacs $@argv --eval '(setq buffer-read-only)' }
]
&helix=[
&e={|@argv| e:helix $@argv }
&v={|@argv| e:helix $@argv } # Pas de lecture seule actuellement
]
&kak=[
&e={|@argv| e:kak $@argv }
&v={|@argv| e:kak -ro $@argv }
]
&nvim=[
&e={|@argv| e:nvim $@argv }
&v={|@argv| e:nvim -R $@argv }
]
&vim=[
&e={|@argv| e:vim $@argv }
&v={|@argv| e:vim -R $@argv }
]
]
var ce~ = $editors[$app]['e']
var cv~ = $editors[$app]['v']
# ÉDITEURS DISPOS
#fn ce {|@argv| e:emacs $@argv }
#fn ce {|@argv| e:helix $@argv }
fn ce {|@argv| e:kak $@argv }
#fn ce {|@argv| e:kak $@argv }
#fn ce {|@argv| e:nvim $@argv }
#fn ce {|@argv| e:vim $@argv }
@ -10,9 +38,9 @@ fn ce {|@argv| e:kak $@argv }
#fn cv {|@argv| ce $@argv --eval '(setq buffer-read-only)' }
## helix (pas le lecture seule pour le moment)
#fn cv {|@argv| ce $@argv }
# kak
fn cv {|@argv| ce -ro $@argv }
## nvim/vim
## kak
#fn cv {|@argv| ce -ro $@argv }
# nvim/vim
#fn cv {|@argv| ce -R $@argv }
edit:add-var vi~ $ce~

View File

@ -22,9 +22,9 @@ var next = [
&fr.kaosx.cf=luence-wg
&luence-wg=luence-client
&luence-ovpn=luence-client
&luence-client=proton_nl5
&proton_nl5=proton_us3
&proton_us3=proton_jp2
# &luence-client=proton_nl5
# &proton_nl5=proton_us3
# &proton_us3=proton_jp2
]
fn -list {|&active=$false|

11
rc.elv
View File

@ -1,9 +1,12 @@
#set-env BAT_THEME Coldark-Cold
set-env BAT_PAGER 'less -RF'
#set-env EDITOR vim
set-env EDITOR kak
#set-env VISUAL 'vim -R'
set-env VISUAL 'kak -ro'
set-env EXA_COLORS 'da=36:*.pdf=4:*.doc=4:*.xls=4:*.docx=4:*.xlsx=4:*.odt=4:*.ods=4'
set-env EDITOR nvim
#set-env EDITOR kak
#set-env EDITOR hx
set-env VISUAL 'nvim -R'
#set-env VISUAL 'kak -ro'
#set-env VISUAL hx
set-env CURRENT_SHELL 'elvish'
set-env STARSHIP_CONFIG ~/.config/starship/starship.toml
set-env PERL5LIB /home/benjamin/perl5/lib/perl5