mirror of
https://github.com/Aider-AI/aider.git
synced 2025-06-10 22:55:00 +00:00
Merge branch 'main' into chat-history
This commit is contained in:
commit
11dd753a8c
3 changed files with 14 additions and 11 deletions
|
@ -1 +1 @@
|
|||
__version__ = "0.9.1-dev"
|
||||
__version__ = "0.10.1-dev"
|
||||
|
|
|
@ -27,7 +27,11 @@ def setup_git(git_root, io):
|
|||
if not io.confirm_ask("No git repo found, create one to track GPT's changes (recommended)?"):
|
||||
return
|
||||
|
||||
repo = git.Repo.init(Path.cwd())
|
||||
git_root = str(Path.cwd().resolve())
|
||||
|
||||
check_gitignore(git_root, io, False)
|
||||
|
||||
repo = git.Repo.init(git_root)
|
||||
global_git_config = git.GitConfigParser([str(Path.home() / ".gitconfig")], read_only=True)
|
||||
with repo.config_writer() as git_config:
|
||||
if not global_git_config.has_option("user", "name"):
|
||||
|
@ -38,9 +42,8 @@ def setup_git(git_root, io):
|
|||
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.")
|
||||
git_root = str(Path.cwd().resolve())
|
||||
check_gitignore(git_root, io, False)
|
||||
return git_root
|
||||
|
||||
return repo.working_tree_dir
|
||||
|
||||
|
||||
def check_gitignore(git_root, io, ask=True):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue