X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=bin%2Ffunction2gene;h=962be188411a6a59d31b893001924bcedba161ec;hb=757a79394267bc9c18f0eebeb7016cf2e07f0c8d;hp=de4915bc4f95ecbdd9c564ffb7de88938658d4c0;hpb=af4fd770f221db1cec02393df378e079c0b9a8fc;p=function2gene.git diff --git a/bin/function2gene b/bin/function2gene index de4915b..962be18 100755 --- a/bin/function2gene +++ b/bin/function2gene @@ -53,8 +53,8 @@ the system =item B<--database> Databases to search, can be specified multiple times. [Defaults to -NCBI, GeneCards and Harvester, the only currently supported -databases.] +NCBI, GeneCards and Harvester, but ensembl and uniprot are also +supported currently.] =item B<--restart-at> @@ -130,7 +130,7 @@ $ERRORS.="restart-at must be one of get, parse or combine\n" if $ERRORS.="unknown database(s)" if @{$options{databases}} and - grep {$_ !~ /^(?:ncbi|genecard|harvester)$/i} @{$options{databases}}; + grep {$_ !~ /^(?:ncbi|genecard|harvester|ensembl|uniprot)$/i} @{$options{databases}}; if (not length $options{results}) { $ERRORS.="results directory not specified"; @@ -192,6 +192,7 @@ if (@{$options{keywords}}) { next if /^\s*[#;]/; next unless /\w+/; chomp; + s/\r$//; my ($keyword,$weight) = split /\t/, $_; $weight = 1 if not defined $weight; $state{keyword_weight}{$keyword} = $weight; @@ -296,6 +297,9 @@ for my $keyword (@{$state{keywords}}) { } } +$SIG{INT} = sub { + save_state(\%state); +}; for my $state (qw(get parse)) { my %databases;