]> git.donarmstrong.com Git - biopieces.git/blob - bp_bin/swapcase_seq
fixes and stuff
[biopieces.git] / bp_bin / swapcase_seq
1 #!/usr/bin/env ruby
2
3 require 'Maasha/biopieces'
4 require 'getoptlong'
5
6 options = GetoptLong.new(
7     [ '--help',       '-?', GetoptLong::NO_ARGUMENT ],
8     [ '--stream_in',  '-I', GetoptLong::REQUIRED_ARGUMENT ],
9     [ '--stream_out', '-O', GetoptLong::REQUIRED_ARGUMENT ],
10     [ '--verbose',    '-v', GetoptLong::NO_ARGUMENT ]
11 )
12
13 if ARGV.length == 0 then
14     biopiece = $0.split( "/" ).last
15     exec "print_wiki --data_in #{ ENV[ 'BP_DIR' ] }/bp_usage/#{ biopiece }.wiki"
16 end
17
18 options.each do | opt, arg |
19     puts "option: #{ opt }   argument: #{ arg }"
20
21     case opt
22         when '--help'
23             biopiece = $0.split( "/" ).last
24             exec "print_wiki --data_in #{ ENV[ 'BP_DIR' ] }/bp_usage/#{ biopiece }.wiki --help"
25         when '--stream_in'
26             puts "Stream in"
27             stream = File.open( arg )
28         when '--stream_out'
29             puts "Stream out"
30         when '--verbose'
31             puts "blababnlbalbalbalbalab"
32     end
33 end
34
35 bp_stream = BioPieces.new( "test.stream" )
36
37 puts bp_stream.record_get