giff 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f9146a75c2f357955beeee13ae9c4c1e8ae2f5353af412fd56735b2e2129bd87
4
- data.tar.gz: daa69f569a9aa35627d2dadc3b19a018eddd9ba79f26203e9149cbb420775e1d
3
+ metadata.gz: 58421ed752742bf64ce45d90610bf9dec2d6865abe97894c5606836d2b7e7d60
4
+ data.tar.gz: 5b8eddab8b3d6e0eb03ae19ee157fcf0e693a43d1ef6ddfa43521e6d8d91396d
5
5
  SHA512:
6
- metadata.gz: 7528a300b3c99cecb6098b03b644b1867c0570569ee11d8b7f926cec6c7163872995139285e51cf6a0cdb41ff96118d76787662120d4feca355bd9dc15f5f6b6
7
- data.tar.gz: 71547b3132c5f09b6e325fe9e230663cb5525f3c467d82a7aaf16cd6e25528e546d0bfb73dcc2af3d9dc5c40e691c817c25280f92afc0ee20dbb6487ad5214a5
6
+ metadata.gz: 5556f64a680f742cdf4622084485e4e5096be32199fd9d48f83e55ed5331f0fd9a5c3695e5bf0cca0a5911f325bb42c553e785450f490aa01a8ed49c64729368
7
+ data.tar.gz: 1457ca47087ae8255e28ce0383173fe1f879863120fd0bfbcc00f40565e8a1e2daf3b6a0e38791e2f5a85f07f5fd67365043bca8416bdc9cd3772cbcd03ffccb
data/exe/giff CHANGED
@@ -2,5 +2,12 @@
2
2
 
3
3
  require "giff"
4
4
 
5
- diff = Giff::Diff.new(ARGV.fetch(0), ARGV.fetch(1))
5
+ begin
6
+ require "open-uri"
7
+ rescue LoadError
8
+ end
9
+
10
+ file_a = open(ARGV.fetch(0))
11
+ file_b = open(ARGV.fetch(1))
12
+ diff = Giff::Diff.new(file_a, file_b)
6
13
  diff.describe
@@ -9,7 +9,7 @@ Gem::Specification.new do |spec|
9
9
  spec.authors = ["John Hawthorn"]
10
10
  spec.email = ["john@hawthorn.email"]
11
11
 
12
- spec.summary = %q{Gem fIFF tool}
12
+ spec.summary = %q{Gem dIFF tool}
13
13
  spec.description = %q{Show the changes between two .gem files}
14
14
  spec.homepage = "https://github.com/jhawthorn/giff"
15
15
 
@@ -41,7 +41,7 @@ module Giff
41
41
  def to_file(file)
42
42
  file = File.open(file) if file.is_a?(String)
43
43
 
44
- if file.is_a?(File)
44
+ if file.respond_to?(:read) # probably a file or IO
45
45
  Giff::GemFile.new(file)
46
46
  else
47
47
  raise ArgumentError, "#{file.inspect} isn't a file"
@@ -1,3 +1,3 @@
1
1
  module Giff
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: giff
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - John Hawthorn
@@ -111,5 +111,5 @@ rubyforge_project:
111
111
  rubygems_version: 2.7.7
112
112
  signing_key:
113
113
  specification_version: 4
114
- summary: Gem fIFF tool
114
+ summary: Gem dIFF tool
115
115
  test_files: []