Emacs has `auto-mode-alist'. VS Code has `files.associations'.
I think he meant a command line option. Like something you can put in FCEDIT
I did. But if there aren't any options to select the syntax editing mode,
you can use an approach like this:
: ${EDITOR:=emacs}
case $1 in
*.bash) FN=$1 MV=':' ;;
*) FN=${1}.bash MV=mv ;;
esac
$MV "$1" "$FN"
$EDITOR "$FN"
$MV "$FN" "$1"
Wrap that in a script or function and assign it to FCEDIT. You could
also use ln and rm instead of mv, but this works. And test it; I didn't.
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU chet@case.edu http://tiswww.cwru.edu/~chet/