From 396dd5abc74aa32a18b2d294d8bc55cbb900bd6d Mon Sep 17 00:00:00 2001 From: martinahansen Date: Mon, 10 Aug 2009 16:03:26 +0000 Subject: [PATCH] added nifty # detail to read_tab git-svn-id: http://biopieces.googlecode.com/svn/trunk@631 74ccb610-7750-0410-82ae-013aeee3265d --- bp_bin/read_tab | 11 ++++++++++- code_perl/Maasha/C_code.pm | 3 --- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/bp_bin/read_tab b/bp_bin/read_tab index 3c78230..f223523 100755 --- a/bp_bin/read_tab +++ b/bp_bin/read_tab @@ -70,7 +70,16 @@ if ( $options->{ 'data_in' } ) next; } - next if $line =~ /^#|^$/; # skip comment lines beginning with # and skip empty lines. + next if $line =~ /^$/; # skip empty lines. + + if ( $line =~ /^#.+/ and not defined $options->{ 'keys' } ) + { + $line = substr $line, 1; + + $options->{ 'keys' } = [ split /$options->{'delimit'}/, $line ]; + + next; + } chomp $line; diff --git a/code_perl/Maasha/C_code.pm b/code_perl/Maasha/C_code.pm index 4b248e9..bbcf3ba 100644 --- a/code_perl/Maasha/C_code.pm +++ b/code_perl/Maasha/C_code.pm @@ -45,13 +45,10 @@ use Inline ( C => Config => use Inline C => << 'END_C'; -void maasha_ping(); - END_C # >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>><<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< -maasha_ping(); 1; -- 2.39.5