forked from qt-creator/qt-creator
Fix the getting of the Git author name when user.name isn't set
The config variable is not required, as Git will get the user's name from other system settings, like the gecos field in /etc/passwd. So adapt Qt Creator to use the same mechanism that Git does. Change-Id: I255870833a024a36adf6ffff13ecb43cc0c45bbf Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
This commit is contained in:
@@ -293,6 +293,7 @@ public:
|
||||
const QString &messge, QString *name,
|
||||
QString *errorMessage = 0) const;
|
||||
|
||||
QString readGitVar(const QString &workingDirectory, const QString &configVar) const;
|
||||
QString readConfigValue(const QString &workingDirectory, const QString &configVar) const;
|
||||
|
||||
QTextCodec *encoding(const QString &workingDirectory, const QByteArray &configVar) const;
|
||||
@@ -370,6 +371,8 @@ private:
|
||||
// determine version as '(major << 16) + (minor << 8) + patch' or 0.
|
||||
unsigned synchronousGitVersion(QString *errorMessage = 0) const;
|
||||
|
||||
QString readOneLine(const QString &workingDirectory, const QStringList &arguments) const;
|
||||
|
||||
enum RevertResult { RevertOk, RevertUnchanged, RevertCanceled, RevertFailed };
|
||||
RevertResult revertI(QStringList files,
|
||||
bool *isDirectory,
|
||||
|
||||
Reference in New Issue
Block a user