lib/unpack.rb in unpack-0.1.7 vs lib/unpack.rb in unpack-0.1.8

- old
+ new

@@ -62,11 +62,10 @@ unpack.wipe! if options[:remove] unpack.diff end def prepare! - @directory.gsub!(/\s+/, '\ ') @files = [] ['zip', 'rar'].each do |type| @files << find_file_type(type) end @@ -162,8 +161,8 @@ def unzip(args) %x(unzip -n '#{args[:file]}' -d '#{args[:path]}') end def find_file_type(file_type) - %x{cd '#{@directory}' && find '#{@directory}' -type f -maxdepth '#{(@options[:depth])}' -name \"*.#{file_type}\"}.split(/\n/) + %x{cd '#{@directory}' && find '#{@directory}' -type f -maxdepth '#{(@options[:depth])}' -name '*.#{file_type}'}.split(/\n/) end end