diff --git a/RedPandaIDE/vcs/gitmanager.cpp b/RedPandaIDE/vcs/gitmanager.cpp index a559cde8..48e76915 100644 --- a/RedPandaIDE/vcs/gitmanager.cpp +++ b/RedPandaIDE/vcs/gitmanager.cpp @@ -587,11 +587,14 @@ QString GitManager::runGit(const QString& workingFolder, const QStringList &args // qDebug()<<"---------"; // qDebug()<dirs().appDir()); #ifdef Q_OS_WIN + env.insert("PATH",pSettings->dirs().appDir()); env.insert("GIT_ASKPASS",includeTrailingPathDelimiter(pSettings->dirs().appDir())+"redpanda-win-git-askpass.exe"); -#else - env.insert("GIT_ASKPASS",includeTrailingPathDelimiter(pSettings->dirs().appDir())+"redpanda-git-askpass.exe"); +#elif defined(Q_OS_LINUX) + env.insert(QProcessEnvironment::systemEnvironment()); + env.insert("LANG","en"); + env.insert("LANGUAGE","en"); + env.insert("GIT_ASKPASS",includeTrailingPathDelimiter(pSettings->dirs().appLibexecDir())+"redpanda-git-askpass"); #endif QString output = runAndGetOutput( fileInfo.absoluteFilePath(), diff --git a/redpanda-git-askpass/main.cpp b/redpanda-git-askpass/main.cpp index f67f6ad8..95f2bdf6 100644 --- a/redpanda-git-askpass/main.cpp +++ b/redpanda-git-askpass/main.cpp @@ -11,7 +11,7 @@ int main(int argc, char *argv[]) Dialog w; if (w.showPrompt(argv[1])==QDialog::Accepted) { char* input = w.getInput().toLocal8Bit().data(); - printf(input); + printf("%s",input); } } return 0;