[csw-devel] SF.net SVN: opencsw:[559] gar-wrapper

skayser at users.sourceforge.net skayser at users.sourceforge.net
Mon Sep 26 18:38:14 CEST 2011


Revision: 559
          http://opencsw.svn.sourceforge.net/opencsw/?rev=559&view=rev
Author:   skayser
Date:     2011-09-26 16:38:13 +0000 (Mon, 26 Sep 2011)
Log Message:
-----------
mgar: fix commits for new build directories

Modified Paths:
--------------
    gar-wrapper/CHANGES
    gar-wrapper/mgar

Modified: gar-wrapper/CHANGES
===================================================================
--- gar-wrapper/CHANGES	2011-09-26 15:50:56 UTC (rev 558)
+++ gar-wrapper/CHANGES	2011-09-26 16:38:13 UTC (rev 559)
@@ -12,6 +12,7 @@
 * FIX "index" now properly encodes file paths with special signs (e.g. '+')
 * FIX "init-existing" now properly removes obsolete gar/ symlinks
 * FIX ~/.garrc variable assignments couldn't cope with tabs (Rafael Ostertag)
+* FIX "commit" didn't include parent when needed #58 (Dagobert Michelsen)
 
 Changes with 0.93 (r543):
 * NEW command "show-var" to show runtime value of recipe vars (Maciej Blizinski)

Modified: gar-wrapper/mgar
===================================================================
--- gar-wrapper/mgar	2011-09-26 15:50:56 UTC (rev 558)
+++ gar-wrapper/mgar	2011-09-26 16:38:13 UTC (rev 559)
@@ -401,8 +401,17 @@
 
 function get_rev() {
   local __file="$1"
-  ( svn info "$__file" || echo "Revision: unknown" ) | grep "^Revision:" | \
-    cut -d: -f2- | tr -d " "
+  local __rev
+  local __vcsinfo=`svn info "$__file"`
+  
+  # some people host their .buildsys in git, fail graceful for show-buildsys
+  [ $? -ne 0 ] && { echo "unknown"; return; }
+
+  __rev=`echo "${__vcsinfo}" | grep ^Revision: | cut -d: -f2- | tr -d " "`
+  # svn revision information for uncomitted directories is gone from
+  # the "info" output with 1.7, was 0 previously.
+  [ -z "${__rev}" ]  && __rev=0
+  echo ${__rev}
 }
 
 function get_repourl() {

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the devel mailing list