gump-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kkoli...@apache.org
Subject svn commit: r1740429 - /gump/live/python/gump/core/update/git.py
Date Thu, 21 Apr 2016 23:42:40 GMT
Author: kkolinko
Date: Thu Apr 21 23:42:40 2016
New Revision: 1740429

URL: http://svn.apache.org/viewvc?rev=1740429&view=rev
Log:
Unconditionally force a fresh git clone.
This is to clean broken git checkouts, and to make sure that core.logAllRefUpdates=false option
is applied.

I plan to revert this commit after the next Gump run.

Modified:
    gump/live/python/gump/core/update/git.py

Modified: gump/live/python/gump/core/update/git.py
URL: http://svn.apache.org/viewvc/gump/live/python/gump/core/update/git.py?rev=1740429&r1=1740428&r2=1740429&view=diff
==============================================================================
--- gump/live/python/gump/core/update/git.py (original)
+++ gump/live/python/gump/core/update/git.py Thu Apr 21 23:42:40 2016
@@ -106,25 +106,28 @@ class GitUpdater(ScmUpdater):
             Run git branch and git config remote.origin.url
             to see whether the branch and URL match
         """
-        cmd = getCmdFromString('git branch',
-                               'check_workspace_branch_' + module.getName(), 
-                               module.getSourceControlStagingDirectory())
-        result = execute(cmd)
+        return (False, 'Unconditionally forcing a fresh working copy. This is a temporary
solution to clean stale checkouts and to update configuration of git. 2016-04-22.')
 
-        if not result.isOk():
-            return (False, 'git branch returned ' + str(result.exit_code))
-        elif not result.hasOutput():
-            return (False, 'git branch didn\'t return any output.')
-
-        current_branch = extract_URL(result, BRANCH_REGEX, 'git branch')
-        if module.getScm().getBranch() != current_branch:
-            return (False, 'Expected branch \'' + module.getScm().getBranch() \
-                        + '\' but working copy was \'' + current_branch + '\'')
-
-        return match_workspace_template(module, 'git config remote.origin.url',
-                                        lambda result:
-                                            tailFileToString(result.getOutput(),
-                                                             1).rstrip())
+#
+#       cmd = getCmdFromString('git branch',
+#                              'check_workspace_branch_' + module.getName(), 
+#                              module.getSourceControlStagingDirectory())
+#       result = execute(cmd)
+#
+#       if not result.isOk():
+#           return (False, 'git branch returned ' + str(result.exit_code))
+#       elif not result.hasOutput():
+#           return (False, 'git branch didn\'t return any output.')
+#
+#       current_branch = extract_URL(result, BRANCH_REGEX, 'git branch')
+#       if module.getScm().getBranch() != current_branch:
+#           return (False, 'Expected branch \'' + module.getScm().getBranch() \
+#                       + '\' but working copy was \'' + current_branch + '\'')
+#
+#       return match_workspace_template(module, 'git config remote.origin.url',
+#                                       lambda result:
+#                                           tailFileToString(result.getOutput(),
+#                                                            1).rstrip())
 
     def getPostProcessCommands(self, module, isUpdate):
         """



Mime
View raw message