Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 10 additions & 5 deletions rp_bin/Ricopili/Utils.pm
Original file line number Diff line number Diff line change
Expand Up @@ -74,12 +74,17 @@ while (my $line = <FILE>){
}
close FILE;

# return config value, if a default is provided that is returned in case
# the value is not set in the config file
# Otherwise the call resuts in a die call
sub trans {
my ($expr) = @_;
unless (exists $conf{$expr}) {
die "config file without entry: $expr\n";
}
$conf{$expr};
my ($expr, $default) = @_;

return $conf{ $expr} if (exists $conf{$expr});

return $default if ( defined $default );

die "config file without entry: $expr\n";
}


Expand Down
3 changes: 2 additions & 1 deletion rp_bin/clump_nav3
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ my $qloc = &trans("queue");
#my $hmloc = &trans("hmloc");
my $email = &trans("email");
my $loloc = &trans("loloc");
my $serial = &trans("serial", 0);


#######################################
Expand Down Expand Up @@ -102,7 +103,7 @@ GetOptions( "outname=s"=> \$outname,
"det=i"=> \$detformat,

"force1"=> \my $force1,
"serial"=> \my $serial,
"serial"=> $serial,
"sepa=i"=> \$sepa,

"noclean"=> \my $noclean,
Expand Down
3 changes: 2 additions & 1 deletion rp_bin/impute_dirsub
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@ my $i2loc = &trans("i2loc");
my $liloc = &trans("liloc");
my $email = &trans("email");
my $loloc = &trans("loloc");
my $serial = &trans("serial", 0);


###############################################
Expand Down Expand Up @@ -511,7 +512,7 @@ GetOptions(
"triset=s"=> \my $trioset_file,

"help"=> \my $help,
"serial"=> \my $serial,
"serial"=> $serial,
"sepa=i"=> \$sepa,

"sleep=i"=> \my $sleep_sw,
Expand Down
3 changes: 2 additions & 1 deletion rp_bin/pcaer
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ my $qloc = &trans("queue");
my $hmloc = &trans("hmloc");
my $email = &trans("email");
my $loloc = &trans("loloc");
my $serial = &trans("serial", 0);

#######################################
## v12: with pops as reference
Expand Down Expand Up @@ -168,7 +169,7 @@ my $sepa = 1;
use Getopt::Long;
GetOptions( "out=s"=> \$outname,
"help"=> \my $help,
"serial"=> \my $serial,
"serial"=> $serial,
"sleep=i"=> \my $sleep_sw,

"trio"=> \my $trio,
Expand Down
3 changes: 2 additions & 1 deletion rp_bin/postimp_navi
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,7 @@ my $qloc = &trans("queue");
my $i2loc = &trans("i2loc");
my $email = &trans("email");
my $loloc = &trans("loloc");
my $serial = &trans("serial", 0);


#exit;
Expand Down Expand Up @@ -359,7 +360,7 @@ GetOptions(
"allsw"=> \my $allsw,
"cox"=> \my $cox,
"outname=s"=> \my $outname,
"serial"=> \my $serial,
"serial"=> $serial,
"sepa=i"=> \$sepa,

"sleep=i"=> \my $sleep_sw,
Expand Down
3 changes: 2 additions & 1 deletion rp_bin/preimp_dir
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ my $qloc = &trans("queue");
my $init = &trans("init");
my $email = &trans("email");
my $loloc = &trans("loloc");
my $serial = &trans("serial", 0);


my $mind=0.02; # per ID
Expand Down Expand Up @@ -133,7 +134,7 @@ use Getopt::Long;
GetOptions(

"trio"=> \my $trio,
"serial"=> \my $serial,
"serial"=> $serial,
"sepa=i"=> \$sepa,

"sleep=i"=> \my $sleep_sw,
Expand Down
3 changes: 2 additions & 1 deletion rp_bin/refdir_navi
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ my $hmloc = &trans("hmloc");
my $email = &trans("email");
my $loloc = &trans("loloc");
my $bcrloc = &trans("bcrloc");
my $serial = &trans("serial", 0);

#######################################

Expand Down Expand Up @@ -186,7 +187,7 @@ GetOptions(
"qheadd=i"=> \$q16_head,
"mac_th=i"=> \$mac_th,
"walltimeplus=i"=> \$walltimeplus,
"serial"=> \my $serial,
"serial"=> $serial,
"sepa=i"=> \$sepa,

);
Expand Down
1 change: 1 addition & 0 deletions rp_bin/rp_config
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ rp_logfiles
---- jobarray and queueing parameters:
----------------------------------------
----------------------------------------
serial 0
batch_jobcommand
batch_memory_request
batch_walltime
Expand Down
4 changes: 2 additions & 2 deletions rp_bin/rp_test_navi
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ print "$rp_header\n";
my $loloc = &trans("loloc");
my $email = &trans("email");
my $force1 = 0;
my $serial = 0;
my $outname = "test";
my $job_bn_th = 1000;
my $sepa = 1;
my $serial = &trans("serial", 0);


#######################################
Expand All @@ -51,7 +51,7 @@ my $walltime = 4;
use Getopt::Long;
GetOptions(
"help"=> \my $help,
"serial"=> \my $serial,
"serial"=> $serial,
"sepa=i"=> \$sepa,
"noldsc"=> \my $noldsc,

Expand Down
4 changes: 2 additions & 2 deletions rp_bin/tarse_navi2
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ my $qloc = &trans("queue");
my $hmloc = &trans("hmloc");
my $loloc = &trans("loloc");
my $email = &trans("email");

my $serial = &trans("serial", 0);



Expand Down Expand Up @@ -65,7 +65,7 @@ GetOptions(
"target=s"=> \$target,
"password=s"=> \$password,

"serial"=> \my $serial,
"serial"=> $serial,
"force1"=> \my $force1,
"sjamem_incr=i"=> \$sjamem_incr,
"outname=s"=> \my $outname,
Expand Down