source: genesis/nodes/node-script.pl@ 7092

Last change on this file since 7092 was 7092, checked in by rick, 15 years ago

Some perl hacker, fancy to write an interactive genesis configurator?

  • Property svn:executable set to *
File size: 537 bytes
Line 
1#!/usr/bin/env perl
2
3sub prompt {
4 ($question, $default) = @_;
5 if ( "$default" ne "" ) {
6 $question = "$question [$default]";
7 }
8 print "$question: ";
9
10 $response = <STDIN>;
11
12 # Kill blank space
13 $response =~ s/^\s+//;
14 $response =~ s/\s+$//;
15
16 # Check if default needs to be set
17 if ( "$response" eq "" ) {
18 $response = $default;
19 }
20 return $response;
21}
22
23$NODE = prompt "Which node do you like to edit","CNodeRabo";
24#$NODE = 'CNodeRabo';
25
26require "./$NODE/wleiden.conf";
27
28$LOCATION = prompt "Location",$location;
29
30
31
Note: See TracBrowser for help on using the repository browser.