3 #=======================================================================
5 # File ID: 8cc27860-f742-11dd-82e0-000475e441b9
6 # Configures, compiles and installs new groovy Subversion from the
7 # repository at svn.collab.net .
10 # ©opyleft 2004- Øyvind A. Holm <sunny@sunbase.org>
11 # License: GNU General Public License version 2 or later, see end of
12 # file for legal stuff.
13 #=======================================================================
35 $progname =~ s/^.*\/(.*?)$/$1/;
36 our $VERSION = "0.00";
38 my $svn_base = "$ENV{HOME}/src/other/subversion";
39 my $svn_clean = "$ENV{HOME}/src/other/subversioni/1.1.x.clean";
41 Getopt
::Long
::Configure
("bundling");
44 "debug" => \
$Opt{'debug'},
45 "help|h" => \
$Opt{'help'},
46 "verbose|v+" => \
$Opt{'verbose'},
47 "version" => \
$Opt{'version'},
49 ) || die("$progname: Option error. Use -h for help.\n");
51 $Opt{'debug'} && ($Debug = 1);
52 $Opt{'help'} && usage
(0);
53 if ($Opt{'version'}) {
58 unless (chdir($svn_clean)) {
59 warn("$svn_clean: Directory not found, installing newest svn-1.x.x .\n");
61 unless (chdir($svn_base)) {
62 die("chdir($svn_base): $!");
64 my_system
("svn co http://svn.collab.net/repos/svn/branches/1.1.x 1.1.x.clean");
67 unless (chdir($svn_clean)) {
68 die("chdir($svn_clean): $!");
75 if (open(PipeFP
, "svn info|")) {
77 # FIXME: Pussyble i18n stuff fucking up grepping here
78 if (/^Revision: (\d+)$/) {
83 length($Revnum) || die("$svn_clean: Revision number not found in directory: $!");
86 my $dest_dir = "$svn_base/subversion-1.1.x.r$Revnum";
91 print("== Running \"$Cmd\"...\n");
92 return($Cmd || die("$Cmd: $!"));
97 print("==== Executing system(\"$Cmd\")...\n");
102 # Print program version {{{
103 print("$progname v$VERSION\n");
108 # Send the help message to stdout {{{
111 if ($Opt{'verbose'}) {
117 Usage: $progname [options] [file [files [...]]]
124 Increase level of verbosity. Can be repeated.
126 Print version information.
128 Print debugging messages.
136 # Print a status message to stderr based on verbosity level {{{
137 my ($verbose_level, $Txt) = @_;
139 if ($Opt{'verbose'} >= $verbose_level) {
140 print(STDERR
"$progname: $Txt\n");
146 # Print a debugging message {{{
148 my @call_info = caller;
149 chomp(my $Txt = shift);
150 my $File = $call_info[1];
152 $File =~ s
#^.*/(.*?)$#$1#;
153 print(STDERR
"$File:$call_info[2] $$ $Txt\n");
160 # Plain Old Documentation (POD) {{{
170 [options] [file [files [...]]]
180 =item B<-h>, B<--help>
182 Print a brief help summary.
184 =item B<-v>, B<--verbose>
186 Increase level of verbosity. Can be repeated.
190 Print version information.
194 Print debugging messages.
204 Made by Øyvind A. Holm S<E<lt>sunny@sunbase.orgE<gt>>.
208 Copyleft © Øyvind A. Holm E<lt>sunny@sunbase.orgE<gt>
209 This is free software; see the file F<COPYING> for legalese stuff.
213 This program is free software: you can redistribute it and/or modify it
214 under the terms of the GNU General Public License as published by the
215 Free Software Foundation, either version 2 of the License, or (at your
216 option) any later version.
218 This program is distributed in the hope that it will be useful, but
219 WITHOUT ANY WARRANTY; without even the implied warranty of
220 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
221 See the GNU General Public License for more details.
223 You should have received a copy of the GNU General Public License along
225 If not, see L<http://www.gnu.org/licenses/>.
233 # vim: set fenc=UTF-8 ft=perl fdm=marker ts=4 sw=4 sts=4 et fo+=w :