git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 3/3] Deprecate author and committer details in stgitrc

From
Karl Hasselström <kha@treskal.com>
Date
Nov 11, 2006, 23:31 UTC
Message-ID
<20061111233121.17760.27045.stgit@localhost>
In-Reply-To
<20061111232322.17760.26214.stgit@localhost>
From: Karl Hasselström <kha@treskal.com>

There are two distinct disadvantages to having author and committer names in stgitrc:

  * They override GIT_AUTHOR_NAME and friends, not the other way
    around as one might imagine.
  * They cause stgit and plain git to use different names (unless one
    manages to keep them in sync manually), which can't possibly be a
    good idea.

This patch removes the description of these variables in the example stgitrc, so that new users aren't tempted to use them. They will still continue to function, however.

Signed-off-by: Karl Hasselström <kha@treskal.com>
---
 examples/stgitrc |    5 -----
 stgit/git.py     |    3 +++
 2 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/examples/stgitrc b/examples/stgitrc
index 45a629b..9cd95e1 100644
--- a/examples/stgitrc
+++ b/examples/stgitrc
@@ -3,11 +3,6 @@
 # the former.
 
 [stgit]
-# Default author/committer details
-#authname:  Your Name
-#authemail: your.name@yourcompany.com
-#commname:  Your Name
-#commemail: your.name@yourcompany.com
 
 # Automatically Bcc the address below
 #autobcc: your.name@yourcompany.com
diff --git a/stgit/git.py b/stgit/git.py
index a6e1a63..f654cde 100644
--- a/stgit/git.py
+++ b/stgit/git.py
@@ -452,6 +452,9 @@ def __git_person(p):
 
 __cached_stgit_persons = {}
 def __stgit_person(p, name_key, email_key):
+    """Calls __git_person to get the details for a person, but allows
+    the deprecated author and committer variables in stgitrc override
+    the result."""
     if not p in __cached_stgit_persons:
         person = __git_person(p)
Previous: Karl HasselströmNext: Karl Hasselström
Message 15 of 17 in “Double From:s in StGIT's patch email template”
  1. Karl HasselströmNov 11, 2006
  2. Author name and e-mail address in .stgitrcKarl Hasselström, Nov 11, 2006
  3. Robin RosenbergNov 11, 2006
  4. Karl HasselströmNov 11, 2006
  5. Robin RosenbergNov 11, 2006
  6. Karl HasselströmNov 11, 2006
  7. Catalin MarinasNov 11, 2006
  8. 0/3 Re: Author name and e-mail address in .stgitrcKarl Hasselström, Nov 11, 2006
  9. 1/3 Ask git for author and committer nameKarl Hasselström, Nov 11, 2006
  10. Karl HasselströmNov 11, 2006
  11. Catalin MarinasDec 4, 2006
  12. Karl HasselströmDec 5, 2006
  13. Catalin MarinasDec 5, 2006
  14. 2/3 Don't mention deprecated template variablesKarl Hasselström, Nov 11, 2006
  15. 3/3 Deprecate author and committer details in stgitrcKarl Hasselström, Nov 11, 2006
  16. Karl HasselströmNov 12, 2006
  17. Karl HasselströmNov 11, 2006

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.