Skip to content

Commit

Permalink
Clear matches after running 'auto none'
Browse files Browse the repository at this point in the history
  • Loading branch information
leo-arch committed Nov 13, 2024
1 parent 97ffdd2 commit 888329e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/autocmds.c
Original file line number Diff line number Diff line change
Expand Up @@ -920,7 +920,13 @@ print_autocmds_list(void)
static int
reload_dir_ignoring_autocmds(void)
{
if (autocmds_n == 0) {
fputs("auto: No autocommand defined\n", stdout);
return FUNC_SUCCESS;
}

revert_autocmd_opts();
unset_autocmd_matches();
dir_changed = 0;
reload_dirlist();
return FUNC_SUCCESS;
Expand Down

0 comments on commit 888329e

Please sign in to comment.