[Utils] Add ability to configure git-llvm-push from .gitconfig - #187398
Merged
boomanaiden154 merged 2 commits intoMar 26, 2026
Conversation
This lets someone set git config options at whatever scope (per-repo, global, etc.) for the options that they care about. This provides similar functionality to just wrapping the script in a shell script with one's desired options without the need to do that. We need to be careful about how when we get the flags and how to execute the git command to get the flags. For now, we do this before normal argument parsing and fail silently to avoid printing output if someone passes something like --quiet through the git config. This means options like --verbose and --dry-run don't work for this specific command, but I think that is a reasonable tradeoff.
Contributor
Author
|
Tested on my fork with boomanaiden154#60 (the history is kind of screwed up currently which is why the diff is so big). |
🐧 Linux x64 Test Results
Failed Tests(click on a test name to see its output) lldb-apilldb-api.functionalities/data-formatter/data-formatter-stl/generic/list/TestDataFormatterGenericList.pyIf these failures are unrelated to your changes (for example tests are broken or flaky at HEAD), please open an issue at https://github.com/llvm/llvm-project/issues and add the |
petrhosek
reviewed
Mar 25, 2026
petrhosek
approved these changes
Mar 25, 2026
ilovepi
approved these changes
Mar 25, 2026
Aadarsh-Keshri
pushed a commit
to Aadarsh-Keshri/llvm-project
that referenced
this pull request
Mar 28, 2026
…187398) This lets someone set git config options at whatever scope (per-repo, global, etc.) for the options that they care about. This provides similar functionality to just wrapping the script in a shell script with one's desired options without the need to do that. We need to be careful about how when we get the flags and how to execute the git command to get the flags. For now, we do this before normal argument parsing and fail silently to avoid printing output if someone passes something like --quiet through the git config. This means options like --verbose and --dry-run don't work for this specific command, but I think that is a reasonable tradeoff.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This lets someone set git config options at whatever scope (per-repo, global, etc.) for the options that they care about. This provides similar functionality to just wrapping the script in a shell script with one's desired options without the need to do that.
We need to be careful about how when we get the flags and how to execute the git command to get the flags. For now, we do this before normal argument parsing and fail silently to avoid printing output if someone passes something like --quiet through the git config. This means options like --verbose and --dry-run don't work for this specific command, but I think that is a reasonable tradeoff.