]> git.donarmstrong.com Git - biopieces.git/commitdiff
added \r remove hack to genbank/embl parsers
authormartinahansen <martinahansen@74ccb610-7750-0410-82ae-013aeee3265d>
Mon, 24 Jun 2013 09:59:49 +0000 (09:59 +0000)
committermartinahansen <martinahansen@74ccb610-7750-0410-82ae-013aeee3265d>
Mon, 24 Jun 2013 09:59:49 +0000 (09:59 +0000)
git-svn-id: http://biopieces.googlecode.com/svn/trunk@2186 74ccb610-7750-0410-82ae-013aeee3265d

code_ruby/lib/maasha/embl.rb
code_ruby/lib/maasha/genbank.rb
code_ruby/lib/maasha/locator.rb

index 29c3eb66503fc805d2fb0fa108d3939bcb002761..6d9d6b5e0bd5ef6278d1754698edbfacb2f9cc7c 100644 (file)
@@ -68,7 +68,7 @@ class EMBL < Filesys
 
     block.chomp!("//" + $/ )
 
-    entry = block.split $/
+    entry = block.tr("\r", "\n").split $/
 
     return nil if entry.empty?
 
index 1cf2038ff45d37c24aa788da47c790865590a7d3..b1c9f8734a7a7f6dac1df4c7a18a3d59a62e2af1 100644 (file)
@@ -68,7 +68,7 @@ class Genbank < Filesys
 
     block.chomp!("//" + $/ )
 
-    entry = block.split $/
+    entry = block.tr("\r", "\n").split $/
 
     return nil if entry.empty?
 
index 638f473d7fdcebe23f13eb9d7d7da9d8dd9970c1..70aa861fa736edb1ad547edd8061930d06aa6277 100644 (file)
@@ -125,7 +125,7 @@ class Locator
                @subseq.seq << (order ? " " + newseq.seq : newseq.seq)
                                        end
         else
-          $stderr.puts "WARNING: Could not match locator -> #{locator}";
+          $stderr.puts "WARNING: Could not match locator ->#{locator}<-";
           @subseq.seq << ""
         end
       end