[Bps-public-commit] r10554 - bpsbuilder/Shipwright/lib/Shipwright
sunnavy at bestpractical.com
sunnavy at bestpractical.com
Tue Jan 29 12:18:02 EST 2008
Author: sunnavy
Date: Tue Jan 29 12:18:01 2008
New Revision: 10554
Modified:
bpsbuilder/Shipwright/lib/Shipwright/Backend.pm
Log:
added help arg for build script
Modified: bpsbuilder/Shipwright/lib/Shipwright/Backend.pm
==============================================================================
--- bpsbuilder/Shipwright/lib/Shipwright/Backend.pm (original)
+++ bpsbuilder/Shipwright/lib/Shipwright/Backend.pm Tue Jan 29 12:18:01 2008
@@ -88,8 +88,32 @@
my %args;
GetOptions( \%args, 'update-order', 'keep-requires=s', 'keep-recommends=s',
- 'keep-build-requires=s', 'for-dists=s' );
+ 'keep-build-requires=s', 'for-dists=s', 'help' );
+my $USAGE = <<'END'
+run: ./bin/shipwright-utility --update-order
+
+options:
+
+help: print this usage
+
+update-order: regenerate install order.
+ sub options:
+ keep-requires: keep dists with requires dep type. default is true.
+ keep-recommends: keep dists with recommends dep type. default is true.
+ keep-build-requires: keep dists with build-requires dep type. default is true.
+ for-dists: make order only for these dists, seperated by comma.
+ default is for all the dists in the source.
+
+ e.g. --update-order --keep-recommends 0 --for-dists Jifty-DBI,Jifty
+
+END
+;
+
+if ( $args{'help'} ) {
+ print $USAGE;
+ exit 0;
+}
if ( $args{'update-order'} ) {
for ( 'keep-requires', 'keep-recommends', 'keep-build-requires' ) {
$args{$_} = 1 unless defined $args{$_};
@@ -176,7 +200,42 @@
my %args;
GetOptions( \%args, 'install-base=s', 'perl=s', 'skip=s', 'skip-test',
- 'only-test', 'force' );
+ 'only-test', 'force', 'help' );
+
+my $USAGE = <<'END'
+run: ./bin/shipwright-builder
+
+options:
+
+help: print this usage
+
+install-base: where we will install
+ defaults: a temp dir below your system's tmp.
+ e.g. --install-base /home/local/mydist
+
+perl: which perl to use for the to be installed dists.
+ defaults: if we have perl in the source, it will use that one.
+ else, it will use the one which runs this builder script.
+ e.g. --perl /usr/bin/perl
+
+skip: dists we don't want to install, comma seperated.
+ e.g. --skip perl,Module-Build
+
+skip-test: skip test part if there're
+
+force: if tests fail, install anyway
+
+only-test: test for the installed dists.
+ it's used to be sure everything is ok after we install with success.
+ need to specify --install-base.
+
+END
+;
+
+if ( $args{'help'} ) {
+ print $USAGE;
+ exit 0;
+}
unlink 'build.log' if -e 'build.log';
open my $log, '>', 'build.log' or die $!;
More information about the Bps-public-commit
mailing list