scm: fix init.

Make sure we actually init and also upon init update the
file list and initialise the local engine.
This commit is contained in:
Al Poole 2017-09-16 20:41:46 +01:00
parent 59a0ec1bae
commit 2c42965b15
2 changed files with 14 additions and 1 deletions

View File

@ -1002,6 +1002,8 @@ _edi_menu_scm_init_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
edi_consolepanel_clear();
edi_consolepanel_show();
edi_scm_git_new();
edi_scm_init();
edi_filepanel_update_all();
_edi_icon_update();
}

View File

@ -58,7 +58,18 @@ _edi_scm_exec_response(const char *command)
EAPI int
edi_scm_git_new(void)
{
return _edi_scm_exec("git init .");
int code;
char *oldpwd;
oldpwd = getcwd(NULL, PATH_MAX);
chdir(edi_project_get());
code = edi_exe_wait("git init .");
chdir(oldpwd);
free(oldpwd);
return code;
}
EAPI int