From: martinahansen <martinahansen@74ccb610-7750-0410-82ae-013aeee3265d>
Date: Fri, 18 Mar 2011 17:03:43 +0000 (+0000)
Subject: filesys now polished
X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=7abe6d1f9384aef4c8370b9cd57f1cac3ef32f58;p=biopieces.git

filesys now polished

git-svn-id: http://biopieces.googlecode.com/svn/trunk@1295 74ccb610-7750-0410-82ae-013aeee3265d
---

diff --git a/code_ruby/Maasha/lib/filesys.rb b/code_ruby/Maasha/lib/filesys.rb
index f7d2b9b..6f6d8cc 100644
--- a/code_ruby/Maasha/lib/filesys.rb
+++ b/code_ruby/Maasha/lib/filesys.rb
@@ -33,21 +33,19 @@ class Filesys
   # Class method allowing open to be used on (zipped) files.
   # See File.open.
   def self.open(*args)
-    pp *args
+    args = *args
+    file = args.first
 
-    tyt = *args
-    if tyt.first == "-"
+    if file == "-"
       ios = self.new(STDIN)
-    elsif File.pipe? *args.first
+    elsif File.pipe? file
       ios = self.new(File.open(*args))
     else
       ios = self.zopen(*args)
     end
 
     if block_given?
-      puts "BLOCK"
       begin
-        puts "YIELD"
         yield ios
       ensure
         ios.close