Skip to content

Commit

Permalink
Match latest git's repo status messages.
Browse files Browse the repository at this point in the history
  • Loading branch information
Wayne Davison committed Jul 31, 2014
1 parent 6ceb9ea commit 6fe7983
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packaging/git-status.pl
Original file line number Diff line number Diff line change
Expand Up @@ -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 = '';
Expand Down
2 changes: 1 addition & 1 deletion packaging/nightly-rsync
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ if ($make_tar) {
open(IN, '-|', 'git status') or die $!;
my $status = join('', <IN>);
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";

Expand Down

0 comments on commit 6fe7983

Please sign in to comment.