summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorPeter Powell <petpow@saberuk.com>2015-02-25 19:57:10 +0000
committerPeter Powell <petpow@saberuk.com>2015-03-06 16:13:11 +0000
commit1dc79dcdff4d68db4c1e0925bc9e747615bb3156 (patch)
tree2ad14ef9183ae660c7a82309305e9244333a5e17 /configure
parent88bfcabe027216022df7b6f410f0dd862a92128d (diff)
Add development version checks to non-interactive mode.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure11
1 files changed, 8 insertions, 3 deletions
diff --git a/configure b/configure
index d7cf0d732..7b1452c5d 100755
--- a/configure
+++ b/configure
@@ -46,6 +46,7 @@ use make::console;
my ($opt_binary_dir,
$opt_config_dir,
$opt_data_dir,
+ $opt_development,
$opt_disable_interactive,
$opt_distribution_label,
$opt_gid,
@@ -71,6 +72,7 @@ GetOptions(
'help' => \&cmd_help,
'update' => \&cmd_update,
+ 'development' => \$opt_development,
'disable-interactive' => \$opt_disable_interactive,
'distribution-label=s' => \$opt_distribution_label,
'binary-dir=s' => \$opt_binary_dir,
@@ -107,6 +109,7 @@ our $interactive = !(
defined $opt_binary_dir ||
defined $opt_config_dir ||
defined $opt_data_dir ||
+ defined $opt_development ||
defined $opt_disable_interactive ||
defined $opt_distribution_label ||
defined $opt_gid ||
@@ -233,7 +236,7 @@ $config{UID} = $user[2];
system 'tput', 'clear' if $interactive;
# Check that the user actually wants this version.
-if ($version{LABEL} ne 'release' && $interactive) {
+if ($version{LABEL} ne 'release') {
print_warning <<'EOW';
You are building a development version. This contains code which has
not been tested as heavily and may contain various faults which could seriously
@@ -242,9 +245,11 @@ version instead.
You can obtain the latest stable version from http://www.inspircd.org/ or by
running `git checkout insp20` if you are installing from Git.
-
EOW
-exit 1 unless prompt_bool $interactive, 'I understand this warning and want to continue anyway.', !$interactive;
+ if (!prompt_bool $interactive, 'I understand this warning and want to continue anyway.', $opt_development || 0) {
+ print STDERR "If you understand this warning and still want to continue pass the --development flag.\n" unless $interactive;
+ exit 1;
+ }
}
# Configure directory settings.