Changeset 1171


Ignore:
Timestamp:
Jun 21, 2008, 6:15:43 PM (13 years ago)
Author:
kake
Message:

Make it clear in SETUP that the script_url needs an http

Location:
branches/new-install-process
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/new-install-process/SETUP

    r1169 r1171  
    174174
    175175Give the full address needed to access the installation directory with
    176 a web browser - for example http://london.openguides.org/
     176a web browser, including the "http://" prefix - for example,
     177http://london.openguides.org/
    177178
    178179
  • branches/new-install-process/bin/openguides-install

    r1158 r1171  
    7979}
    8080
    81 # The database setup script.
    82 my $setup = find_script( "wiki-toolkit-setupdb" );
    83 
    8481my $force;
    8582GetOptions('force' => \$force);
     
    116113      content_above_navbar_in_html show_gmap_in_node_display force_wgs84
    117114      send_moderation_notifications);
     115
     116my %blank_ok = map { $_ => 1 }
     117   qw( dbpass dbhost );
    118118
    119119my $skip_config = $force ? 'y'
     
    167167              );
    168168eval "require $drivers{$dbtype}";
    169 warn "$drivers{$dbtype} is needed to run a $dbtype database" if $@;
     169die "\nSorry; $drivers{$dbtype} is needed to run a $dbtype database - please "
     170    . "install this\nmodule and try again.\n\n" if $@;
    170171
    171172push @answers, { question => $dbtype_qu,
     
    206207    my $q_method = $var . "__qu";
    207208    my $qu  = $existing_config->$q_method;
    208     my $type = $yn_vars{$var} ? "y_n" : "";
    209209    my $def = $existing_config->$var || "";
    210210    my $val = $def;
     
    212212    # Override dbname question for SQLite only.
    213213    if ( $dbtype eq "sqlite" and $var eq "dbname" ) {
    214         $qu = "what's the full filename of the SQLite database this site runs on?";
     214        $qu = "What's the full filename of the SQLite database this site runs on?";
    215215    }
    216216
     
    323323    # Here is where we actually ask the questions.
    324324    unless ( $skip_config ) {
    325         if ( $type eq "y_n" ) {
     325print $var . "\n";
     326        if ( $yn_vars{$var} ) {
    326327            # may be stored as true/false integer value
    327328            if ( $def =~ /^\d+$/ ) {
     
    329330            }
    330331            $val = prompt( "y", $qu, "y or n", $def );
     332        } elsif ( $blank_ok{$var} ) {
     333print "boo!\n";
     334             $val = prompt( "s", $qu, "optional", $def,
     335                            sub { print "hello!\n"; return 1; } );
    331336        } else {
    332337             $val = prompt( "x", $qu, "", $def );
Note: See TracChangeset for help on using the changeset viewer.