mirror of
https://github.com/Aider-AI/aider.git
synced 2025-06-11 07:04:59 +00:00
provide default git name/email; fix tests
This commit is contained in:
parent
451929f2ca
commit
031c2bc34b
2 changed files with 25 additions and 6 deletions
|
@ -265,9 +265,13 @@ def main(args=None, input=None, output=None):
|
|||
repo = git.Repo.init(os.getcwd())
|
||||
with repo.config_writer() as git_config:
|
||||
if not git_config.has_option("user", "name"):
|
||||
git_config.set_value("user", "name", "Example Name")
|
||||
git_config.set_value("user", "name", "Your Name")
|
||||
io.tool_error('Update git name with: git config --global user.name "Your Name"')
|
||||
if not git_config.has_option("user", "email"):
|
||||
git_config.set_value("user", "email", "example.email@example.com")
|
||||
git_config.set_value("user", "email", "you@example.com")
|
||||
io.tool_error(
|
||||
'Update git email with: git config --global user.email "you@example.com"'
|
||||
)
|
||||
io.tool_output("Git repository created in the current working directory.")
|
||||
|
||||
if args.verbose:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue