fix(startup): init.lua: set $MYVIMRC to absolute path #15748

- main.c: remove os_setenv("MYVIMRC",…), it is already done by
  do_source().
  - This also sets $MYVIMRC to a full (absolute) path.
- code cleanup.
This commit is contained in:
Justin M. Keyes
2021-09-21 08:47:46 -07:00
committed by GitHub
parent c208993026
commit c76cddf3e0
4 changed files with 15 additions and 13 deletions

View File

@@ -2112,7 +2112,7 @@ int do_source(char_u *fname, int check_other, int is_vimrc)
verbose_leave();
}
if (is_vimrc == DOSO_VIMRC) {
vimrc_found(fname_exp, (char_u *)"MYVIMRC");
vimrc_found((char *)fname_exp, "MYVIMRC");
}
#ifdef USE_CRNL