Moved things around with nvim to allow multiple configurations, with nvims command

This commit is contained in:
Michael Housh
2023-09-23 20:39:33 -04:00
parent 6204b5f7b3
commit 8d396ff46f
37 changed files with 66 additions and 8 deletions

View File

@@ -22,5 +22,5 @@ fi
printf "#!/bin/%s\n\n" "${shell}" > "${path}"
chmod +x "${path}"
exec vim +2 "${path}"
exec "${EDITOR}" +2 "${path}"

16
scripts/scripts/nvims Executable file
View File

@@ -0,0 +1,16 @@
#!/bin/sh
# Change / select an nvim configuration.
main() {
items=("default" "m-housh" "kickstart" "lazy")
config=$(printf "%s\n" "${items[@]}" | fzf --prompt=" Neovim Config ➣ " --height=50% --layout=reverse --border --exit-0)
if [[ -z $config ]]; then
echo "Nothing selected"
return 0
elif [[ $config == "default" ]]; then
config=""
fi
unset VIMINIT && unset MYVIMRC && export NVIM_APPNAME=$config && nvim $@
}
main "$@"