1 2 3 4 5 6 7 8 9 10 11 12
PRIMARY_USER=till if (($+commands[nvim])); then EDITOR=nvim elif (($+commands[vim])); then EDITOR=vim elif (($+commands[vi])); then EDITOR=vi else EDITOR=nano fi