-
Notifications
You must be signed in to change notification settings - Fork 467
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
Commit using configured git config user.email
to honor GH private email security setting
#4235
Comments
Thanks a lot for reporting! I took a quick look and it seems like we are only asking the Git configuration for user information. This is usually correct enough. Could you help me understand how |
That file is being picked up because
$ env | grep XDG
XDG_RUNTIME_DIR=/run/user/1000/
XDG_CONFIG_HOME=/home/juan/.config
XDG_CACHE_HOME=/home/juan/.cache
XDG_DATA_HOME=/home/juan/.local/share As a test I also set $ git config --show-origin --show-scope --get-all user.email
global file:/home/juan/.config/git/config [email protected]
local file:.git/config [email protected]
$ git config --show-origin --show-scope --get-all user.name
global file:/home/juan/.config/git/config Juan P Barrios
local file:.git/config Juan P Barrios But still got the error after restarting
|
That's a great idea! gitbutler/crates/gitbutler-core/src/virtual_branches/controller.rs Lines 925 to 929 in 82c3987
That gitbutler/crates/gitbutler-core/src/users/user.rs Lines 10 to 13 in de00e4f
I am going to CC @krlvi here as changing it would be easy, but it's also changing something that was probably done for a reason. |
Great news. Glad you managed to hone in on the potential culprit! 🔥 |
Issue
Testing the Git authentication on a new GB Project fails with the default "Use a Git executable" option as the commit is pushed with my GB profile's email address, instead of the one set in my global git configuration.
This is related to the GH email setting "Block command line pushes that expose my email".
![](https://private-user-images.githubusercontent.com/4416345/345431042-371d5d53-cc4d-46d3-ab71-26cc5e7ff52b.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjAzNDY0OTEsIm5iZiI6MTcyMDM0NjE5MSwicGF0aCI6Ii80NDE2MzQ1LzM0NTQzMTA0Mi0zNzFkNWQ1My1jYzRkLTQ2ZDMtYWI3MS0yNmNjNWU3ZmY1MmIucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDcwNyUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA3MDdUMDk1NjMxWiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9NzE0YmM4OWZlNDE3YjViMmYwODg1OGRiYjJlYTQ4N2Y5ZDgzMWY0OWZhYTU3YzUyMzE3MjdlZGZlMGQ3YjRjNiZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.dNYux2QGi4Z-xJw-9pssVnCeOewoRZ-a8XAxZpIxGow)
Additional context
I have the gh CLI set up as a credential helper
Choosing "Use a Git credentials helper" also doesn't work
Related
#2883 (comment)_
The text was updated successfully, but these errors were encountered: