Skip to content

Commit

Permalink
change syn_generic shortcut
Browse files Browse the repository at this point in the history
  • Loading branch information
adsr committed Apr 6, 2024
1 parent 6339749 commit d180016
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion editor.c
Original file line number Diff line number Diff line change
Expand Up @@ -2537,7 +2537,7 @@ static int _editor_init_from_args(editor_t *editor, int argc, char **argv) {
}
break;
case 'y':
editor->syntax_override = strcmp(optarg, "-") == 0 ? "syn_generic" : optarg;
editor->syntax_override = strcmp(optarg, "y") == 0 ? "syn_generic" : optarg;
break;
case 'z':
editor->trim_paste = atoi(optarg) ? 1 : 0;
Expand Down
4 changes: 2 additions & 2 deletions tests/func/test_syntax.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ bbb "aaa" bbb "aaa" bbb
bbb "aaa \" aaa" bbb "aaa \" aaa" bbb
bbb "aaa \" aaa\\" bbb "aaa \" aaa\\" bbb
EOD
extra_opts=(-y- $tmpf)
extra_opts=(-yy $tmpf)
macro=''
declare -A expected
declare -A not_expected
Expand All @@ -63,7 +63,7 @@ cat >$tmpf <<"EOD"
/*bb"bb*/ "aa/*aa"
/*bb"bb"bb*/ "aa/*aa*/aa"
EOD
extra_opts=(-y- $tmpf)
extra_opts=(-yy $tmpf)
macro=''
declare -A expected
declare -A not_expected
Expand Down

0 comments on commit d180016

Please sign in to comment.