mirror of
https://github.com/Aider-AI/aider.git
synced 2025-06-26 22:45:00 +00:00
fix: Update Co-authored-by email to aider@aider.chat
This commit is contained in:
parent
14af218ea2
commit
e2d3fc4594
2 changed files with 4 additions and 6 deletions
|
@ -165,7 +165,7 @@ class GitRepo:
|
||||||
- --attribute-author: Modify Author name to "User Name (aider)".
|
- --attribute-author: Modify Author name to "User Name (aider)".
|
||||||
- --attribute-committer: Modify Committer name to "User Name (aider)".
|
- --attribute-committer: Modify Committer name to "User Name (aider)".
|
||||||
- --attribute-co-authored-by: Add
|
- --attribute-co-authored-by: Add
|
||||||
"Co-authored-by: aider (<model>) <noreply@aider.chat>" trailer to commit message.
|
"Co-authored-by: aider (<model>) <aider@aider.chat>" trailer to commit message.
|
||||||
|
|
||||||
Behavior Summary:
|
Behavior Summary:
|
||||||
|
|
||||||
|
@ -249,9 +249,7 @@ class GitRepo:
|
||||||
model_name = "unknown-model"
|
model_name = "unknown-model"
|
||||||
if coder and hasattr(coder, "main_model") and coder.main_model.name:
|
if coder and hasattr(coder, "main_model") and coder.main_model.name:
|
||||||
model_name = coder.main_model.name
|
model_name = coder.main_model.name
|
||||||
commit_message_trailer = (
|
commit_message_trailer = f"\n\nCo-authored-by: aider ({model_name}) <aider@aider.chat>"
|
||||||
f"\n\nCo-authored-by: aider ({model_name}) <noreply@aider.chat>"
|
|
||||||
)
|
|
||||||
|
|
||||||
# Determine if author/committer names should be modified
|
# Determine if author/committer names should be modified
|
||||||
# Author modification applies only to aider edits.
|
# Author modification applies only to aider edits.
|
||||||
|
|
|
@ -300,7 +300,7 @@ class TestRepo(unittest.TestCase):
|
||||||
|
|
||||||
# check the commit message and author/committer
|
# check the commit message and author/committer
|
||||||
commit = raw_repo.head.commit
|
commit = raw_repo.head.commit
|
||||||
self.assertIn("Co-authored-by: aider (gpt-test) <noreply@aider.chat>", commit.message)
|
self.assertIn("Co-authored-by: aider (gpt-test) <aider@aider.chat>", commit.message)
|
||||||
self.assertEqual(commit.message.splitlines()[0], "Aider edit")
|
self.assertEqual(commit.message.splitlines()[0], "Aider edit")
|
||||||
# With default (None), co-authored-by takes precedence
|
# With default (None), co-authored-by takes precedence
|
||||||
self.assertEqual(
|
self.assertEqual(
|
||||||
|
@ -355,7 +355,7 @@ class TestRepo(unittest.TestCase):
|
||||||
# check the commit message and author/committer
|
# check the commit message and author/committer
|
||||||
commit = raw_repo.head.commit
|
commit = raw_repo.head.commit
|
||||||
self.assertIn(
|
self.assertIn(
|
||||||
"Co-authored-by: aider (gpt-test-combo) <noreply@aider.chat>", commit.message
|
"Co-authored-by: aider (gpt-test-combo) <aider@aider.chat>", commit.message
|
||||||
)
|
)
|
||||||
self.assertEqual(commit.message.splitlines()[0], "Aider combo edit")
|
self.assertEqual(commit.message.splitlines()[0], "Aider combo edit")
|
||||||
# When co-authored-by is true BUT author/committer are explicit True,
|
# When co-authored-by is true BUT author/committer are explicit True,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue