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

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Pavel Roskin <proski@xxxxxxx>
---

 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..0aee6bf 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())
+        tree_id = git.fetch_head()
+        if tree_id != git.get_head():
+            print 'rebasing to "%s"...' % tree_id
+            git.reset(tree_id)
     print 'done'
 
     # push the patches back

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]