-
Notifications
You must be signed in to change notification settings - Fork 133
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide a useful default user ident on Windows #45
Conversation
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
/submit |
Submitted as pull.45.git.gitgitgadget@gmail.com |
We do have the excellent GetUserInfoEx() function to obtain more detailed information of the current user (if the user is part of a Windows domain); Let's use it. Suggested by Lutz Roeder. To avoid the cost of loading Secur32.dll (even lazily, loading DLLs takes a non-neglibile amount of time), we use the established technique to load DLLs only when, and if, needed. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
When a user is registered in a Windows domain, it is really easy to obtain the email address. So let's do that. Suggested by Lutz Roeder. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Found multiple candidates in gitster/git: Using the first one. |
This branch is now known as |
This patch series was integrated into pu via git@16ce0b9. |
This patch series was integrated into next via git@16ce0b9. |
This patch series was integrated into master via git@16ce0b9. |
Closed via 16ce0b9. |
On Linux, we use the gecos information to come up with a sensible user name/email. On Windows, there is no gecos. But there is something comparable, and with these patches, we use it.
This has been carried in Git for Windows for three years, and is considered mature.
Changes since v1:
static
keyword fromwbuffer
: it does not need to persist.