lib/rickshaw.rb in rickshaw-0.0.1 vs lib/rickshaw.rb in rickshaw-0.0.2
- old
+ new
@@ -1,18 +1,18 @@
-require 'digest/sha1'
-require 'rickshaw/version'
-require 'core_ext/string/to_sha1'
-
-module Rickshaw
- module SHA1
- def self.hash(file_path)
- hash = Digest::SHA1.new
- open(file_path, 'r') do |io|
- until io.eof?
- buffer = io.read(1024)
- hash.update(buffer)
- end
- end
- hash.hexdigest
- end
- end
-end
+require 'digest/sha1'
+require 'rickshaw/version'
+require 'core_ext/string/to_sha1'
+
+module Rickshaw
+ module SHA1
+ def self.hash(file_path)
+ hash = Digest::SHA1.new
+ open(file_path, 'r') do |io|
+ until io.eof?
+ buffer = io.read(1024)
+ hash.update(buffer)
+ end
+ end
+ hash.hexdigest
+ end
+ end
+end