gyazo 0.2.0 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. data/lib/gyazo.rb +3 -1
  2. data/test/test_gyazo.rb +7 -0
  3. metadata +4 -4
@@ -6,7 +6,7 @@ require 'net/http'
6
6
  require 'json'
7
7
 
8
8
  class Gyazo
9
- VERSION = '0.2.0'
9
+ VERSION = '0.2.1'
10
10
 
11
11
  def initialize(app = '/Applications/Gyazo.app')
12
12
  @user = IO.popen("whoami", "r+").gets.chomp
@@ -22,6 +22,8 @@ class Gyazo
22
22
  @host = 'gyazo.com'
23
23
  end
24
24
 
25
+ attr_accessor :id
26
+
25
27
  def info(gyazoid)
26
28
  gyazoid =~ /[0-9a-f]{32}/
27
29
  gyazoid = $&
@@ -12,4 +12,11 @@ class TestGyazo < Test::Unit::TestCase
12
12
  assert_equal(url,'http://gyazo.com/6bdded98323cba83530daae7fa7881f9')
13
13
  # assert_equal(url,'http://gyazo.com/a2a2a8154340bd33e9cd5eeea1efd832')
14
14
  end
15
+
16
+ def test_id
17
+ g = Gyazo.new
18
+ assert g.id =~ /^[0-9a-f]+$/
19
+ g.id = '12345'
20
+ assert g.id == '12345'
21
+ end
15
22
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gyazo
3
3
  version: !ruby/object:Gem::Version
4
- hash: 23
4
+ hash: 21
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 2
9
- - 0
10
- version: 0.2.0
9
+ - 1
10
+ version: 0.2.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Toshiyuki Masui
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2013-02-10 00:00:00 Z
18
+ date: 2013-02-21 00:00:00 Z
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: rdoc