[libmoosex-has-sugar-perl] 06/120: really use --pull again, cleanup code

Intrigeri intrigeri at moszumanska.debian.org
Wed Aug 27 21:35:05 UTC 2014


This is an automated email from the git hooks/post-receive script.

intrigeri pushed a commit to annotated tag 0.05070422-source
in repository libmoosex-has-sugar-perl.

commit ec50d72e09d062aab9cbc03fbb435741ab8115bf
Author: Kent Fredric <kentfredric at gmail.com>
Date:   Tue Sep 10 13:28:37 2013 +1200

    really use --pull again, cleanup code
---
 sync_tree.pl | 24 ++++++++++++------------
 1 file changed, 12 insertions(+), 12 deletions(-)

diff --git a/sync_tree.pl b/sync_tree.pl
index 28b91dd..e9b2476 100644
--- a/sync_tree.pl
+++ b/sync_tree.pl
@@ -8,17 +8,17 @@ my $root = find_dev('./');
 
 chdir "$root";
 
-if ( not -d -e $root->child("maint") ) {
-    system(
-        'git', 'subtree', 'add', 
-            '--prefix=maint', 
-            'https://github.com/kentfredric/travis-scripts.git', 'master'
-    );
-} else {
-    system(
-        'git', 'subtree', 'merge', 
-            '--prefix=maint', 'master'
-#            'https://github.com/kentfredric/travis-scripts.git', 'master'
-    );
+sub git_subtree {
+    system('git','subtree', @_ ) == 0 or die "Git subtree had nonzero exit";
+}
+
+my $travis = 'https://github.com/kentfredric/travis-scripts.git';
+my $prefix = 'maint';
+
+if ( not -d -e $root->child($prefix) ) {
+  git_subtree('add','--prefix=' . $prefix , $travis, 'master' );
+}
+else {
+  git_subtree('pull','--prefix=' . $prefix , $travis, 'master' );
 }
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libmoosex-has-sugar-perl.git



More information about the Pkg-perl-cvs-commits mailing list