Only detect git when first run

This commit is contained in:
Roy Qu 2022-02-26 19:42:50 +08:00
parent 030486ef01
commit 14241450cc
1 changed files with 2 additions and 5 deletions

View File

@ -185,6 +185,8 @@ int main(int argc, char *argv[])
default:
setTheme("default");
}
//auto detect git in path
pSettings->vcs().detectGitInPath();
}
auto settings = std::unique_ptr<Settings>(pSettings);
@ -204,11 +206,6 @@ int main(int argc, char *argv[])
//set default open folder
QDir::setCurrent(pSettings->environment().defaultOpenFolder());
//auto detect git in path
if (!pSettings->vcs().gitOk()) {
pSettings->vcs().detectGitInPath();
}
MainWindow mainWindow;
pMainWindow = &mainWindow;
if (app.arguments().count()>1) {