Re: [QGIT PATCH] Add safeguards to Git::userInfo()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 07/10/2008 20:03, Marco Costalba wrote:
On Tue, Oct 7, 2008 at 6:38 PM, Abdelrazak Younes<younes@xxxxxxx>  wrote:
So how do you explain this:


Form git-config(1) docs:

This command will fail if:

-The config file is invalid,
......
-you use --global option without $HOME being properly set.


So please try to comment out following line

--- a/src/git.cpp
+++ b/src/git.cpp
@@ -345,7 +345,7 @@ void Git::userInfo(SList info) {
  	info.clear();
  	info<<  "Environment"<<  user<<  email;

-	errorReportingEnabled = false; // 'git config' could fail, see docs
+	//errorReportingEnabled = false; // 'git config' could fail, see docs

  	run("git config user.name",&user);
  	run("git config user.email",&email);


run from double click and you probably will see an error message box
where git says $HOME is not set (I can reproduce this now).

Right!

So what I think is that when you run from command line there is the
$HOME variable set and command does not fails.

I see... but the only variable I have is HOMEPATH:

HOMEPATH=\Users\abdel

So I guess this was set by msysgit at installation time. But I see this variable only at the console (after typing 'set'), I don't see it in the user environment variable nor in the system one. So I guess the fix would be for msysgit to create this entry?

Thanks,
Abdel.

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux