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

[PATCH] Don't print "rebasing" if the head doesn't change

From
PRPavel Roskin <proski@gnu.org>
Date
Feb 4, 2007, 17:44 UTC
Message-ID
<20070204174403.7926.29304.stgit@dv.roinet.com>
Signed-off-by: Pavel Roskin <proski@gnu.org>
---
Please ignore previous version of this patch; it was buggy.
---
 stgit/commands/pull.py |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/stgit/commands/pull.py b/stgit/commands/pull.py
index b63ef7a..2d4a782 100644
--- a/stgit/commands/pull.py
+++ b/stgit/commands/pull.py
@@ -73,8 +73,10 @@ def func(parser, options, args):
     print 'Pulling from "%s"...' % repository
     git.fetch(repository)
     if (config.get('stgit.pull-does-rebase') == 'yes'):
-        print 'rebasing to "%s"...' % git.fetch_head()
-        git.reset(tree_id = git.fetch_head())
+        fetch_head = git.fetch_head()
+        if fetch_head != git.get_head():
+            print 'rebasing to "%s"...' % fetch_head
+            git.reset(tree_id = fetch_head)
     print 'done'
 
     # push the patches back
Next: Catalin Marinas
Message 1 of 2 in “Don't print "rebasing" if the head doesn't change”
  1. Don't print "rebasing" if the head doesn't changePavel Roskin, Feb 4, 2007
  2. Catalin MarinasFeb 4, 2007

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.