summaryrefslogtreecommitdiffstats
path: root/checksetup.pl
diff options
context:
space:
mode:
authorDavid Lawrence <dkl@mozilla.com>2015-04-13 19:17:10 +0200
committerDavid Lawrence <dkl@mozilla.com>2015-04-13 19:17:52 +0200
commitab7e4149471d48fb00bcbbf59ceafdde87782c51 (patch)
treee9008a640be00ff9e5a1d32dcaf8aa5ef2893ea7 /checksetup.pl
parent7b7e0cc4000fa15305a8f76f580b3a2dd22a04ee (diff)
downloadbugzilla-ab7e4149471d48fb00bcbbf59ceafdde87782c51.tar.gz
bugzilla-ab7e4149471d48fb00bcbbf59ceafdde87782c51.tar.xz
Bug 1152360: backport upstream bug 1143005 that adds a parameter to checksetup.pl for generating cpanfile for dependency resolution
Diffstat (limited to 'checksetup.pl')
-rwxr-xr-xchecksetup.pl18
1 files changed, 15 insertions, 3 deletions
diff --git a/checksetup.pl b/checksetup.pl
index 501138c6d..d3b4cc1d7 100755
--- a/checksetup.pl
+++ b/checksetup.pl
@@ -68,13 +68,19 @@ Bugzilla::Install::Util::no_checksetup_from_cgi() if $ENV{'SERVER_SOFTWARE'};
init_console();
my %switch;
-GetOptions(\%switch, 'help|h|?', 'check-modules', 'no-templates|t',
- 'verbose|v|no-silent', 'make-admin=s',
- 'reset-password=s', 'version|V');
+GetOptions(\%switch, 'help|h|?', 'check-modules', 'cpanfile',
+ 'no-templates|t', 'verbose|v|no-silent',
+ 'make-admin=s', 'reset-password=s', 'version|V');
# Print the help message if that switch was selected.
pod2usage({-verbose => 1, -exitval => 1}) if $switch{'help'};
+# Export cpanfile and exit
+if ($switch{cpanfile}) {
+ export_cpanfile();
+ exit;
+}
+
# Read in the "answers" file if it exists, for running in
# non-interactive mode.
my $answers_file = $ARGV[0];
@@ -280,6 +286,12 @@ the L</"RUNNING CHECKSETUP NON-INTERACTIVELY"> section.
Display this help text
+=item B<--cpanfile>
+
+Outputs a cpanfile in the document root listing the current and optional
+modules with their respective versions. This file can be used by <cpanm>
+and other utilities used to install Perl dependencies.
+
=item B<--check-modules>
Only check for correct module dependencies and quit afterward.