mirror of
git://git.sv.gnu.org/nano.git
synced 2024-11-22 04:41:21 +03:00
bindings: set up modern bindings also when binary's name starts with "e"
This allows activating the "modern" bindings without having to pass an option, by simply invoking nano through a symlink -- for example: `en` (short for "editor nano"), or `et` (short for "edit"), or just `e`.
This commit is contained in:
parent
a27da0d75b
commit
580eaf29d6
@ -1853,6 +1853,8 @@ int main(int argc, char **argv)
|
||||
/* If the executable's name starts with 'r', activate restricted mode. */
|
||||
if (*(tail(argv[0])) == 'r')
|
||||
SET(RESTRICTED);
|
||||
else if (*(tail(argv[0])) == 'e')
|
||||
SET(MODERN_BINDINGS);
|
||||
|
||||
while ((optchr = getopt_long(argc, argv, "ABC:DEFGHIJ:KLMNOPQ:RS$T:UVWX:Y:Z"
|
||||
"abcdef:ghijklmno:pqr:s:tuvwxy!%_0/", long_options, NULL)) != -1) {
|
||||
|
Loading…
Reference in New Issue
Block a user