From: Wayne Davison Date: Thu, 31 Jul 2014 21:43:32 +0000 (-0700) Subject: Match latest git's repo status messages. X-Git-Tag: v3.1.2pre1~40 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6fe798392bdbdeb34d01b15de7f0123df3bbe850;p=thirdparty%2Frsync.git Match latest git's repo status messages. --- diff --git a/packaging/git-status.pl b/packaging/git-status.pl index 32cd437d..9d322e65 100644 --- a/packaging/git-status.pl +++ b/packaging/git-status.pl @@ -35,8 +35,8 @@ sub check_git_status my($fatal_unless_clean, $subdir) = @_; $subdir = '.' unless defined $subdir; my $status = `cd '$subdir' && git status`; - my $is_clean = $status =~ /\nnothing to commit \(working directory clean\)/; - my($cur_branch) = $status =~ /^# On branch (.+)\n/; + my $is_clean = $status =~ /\nnothing to commit.+working directory clean/; + my($cur_branch) = $status =~ /^(?:# )?On branch (.+)\n/; if ($fatal_unless_clean && !$is_clean) { if ($subdir eq '.') { $subdir = ''; diff --git a/packaging/nightly-rsync b/packaging/nightly-rsync index 3aaabcb2..c33a7da9 100755 --- a/packaging/nightly-rsync +++ b/packaging/nightly-rsync @@ -39,7 +39,7 @@ if ($make_tar) { open(IN, '-|', 'git status') or die $!; my $status = join('', ); close IN; - die "The checkout is not clean:\n", $status unless $status =~ /\nnothing to commit \(working directory clean\)/; + die "The checkout is not clean:\n", $status unless $status =~ /\nnothing to commit.+working directory clean/; die "The checkout is not on the master branch.\n" unless $status =~ /^# On branch master\n/; system "make $gen_target" and die "make $gen_target failed!\n";