diff options
Diffstat (limited to 'WebKitTools/Scripts/update-webkit')
-rwxr-xr-x | WebKitTools/Scripts/update-webkit | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/WebKitTools/Scripts/update-webkit b/WebKitTools/Scripts/update-webkit index 5f72869..e562cc0 100755 --- a/WebKitTools/Scripts/update-webkit +++ b/WebKitTools/Scripts/update-webkit @@ -1,6 +1,7 @@ #!/usr/bin/perl -w -# Copyright (C) 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. +# Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. +# Copyright (C) 2009 Google Inc. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions @@ -34,6 +35,7 @@ use lib $FindBin::Bin; use File::Basename; use File::Spec; use Getopt::Long; +use VCSUtils; use webkitdirs; sub runSvnUpdate(); @@ -43,6 +45,8 @@ sub normalizePath($); my $quiet = ''; my $showHelp; +determineIsChromium(); + my $getOptionsResult = GetOptions( 'h|help' => \$showHelp, 'q|quiet' => \$quiet, @@ -51,6 +55,7 @@ my $getOptionsResult = GetOptions( if (!$getOptionsResult || $showHelp) { print STDERR <<__END__; Usage: @{[ basename($0) ]} [options] + --chromium also update dependencies of the chromium port -h|--help show the help message -q|--quiet pass -q to svn update for quiet updates __END__ @@ -60,6 +65,9 @@ __END__ my @svnOptions = (); push @svnOptions, '-q' if $quiet; +# Don't prompt when using svn-1.6 or newer. +push @svnOptions, qw(--accept postpone) if isSVNVersion16OrNewer(); + chdirWebKit(); print "Updating OpenSource\n" unless $quiet; runSvnUpdate(); @@ -68,6 +76,8 @@ if (-d "../Internal") { chdir("../Internal"); print "Updating Internal\n" unless $quiet; runSvnUpdate(); +} elsif (isChromium()) { + system("perl", "WebKitTools/Scripts/update-webkit-chromium") == 0 or die $!; } elsif (isAppleWinWebKit()) { system("perl", "WebKitTools/Scripts/update-webkit-auxiliary-libs") == 0 or die; } @@ -80,7 +90,7 @@ sub runSvnUpdate() my @conflictedChangeLogs; while (my $line = <UPDATE>) { print $line; - $line =~ m/^C\s+(.*\S+)\s*$/; + $line =~ m/^C\s+(.+?)[\r\n]*$/; if ($1) { my $filename = normalizePath($1); push @conflictedChangeLogs, $filename if basename($filename) eq "ChangeLog"; |