gem-src 0.6.1 → 0.6.3

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
  SHA1:
3
- metadata.gz: 49616d662bfc4d63838e221b220a0159b0d28c59
4
- data.tar.gz: 39f4410194d7b0bc0e3e42e6ae41351a63afc6a8
3
+ metadata.gz: 8eb6569d5fed4a776a3eef80df925101d098a099
4
+ data.tar.gz: d9089aac9f20e1ba08abe174cd13a6331dfdd860
5
5
  SHA512:
6
- metadata.gz: a0a8e311d525ebf2ef63b19595f05a03b5f668a2ea5734b870c509aaf83f7f57b691582139445ee5fbc4ce15fcf521e6ab1a36d043c3d267410307dfe0469c50
7
- data.tar.gz: 6866e89026ee3890f115d2b6e9831aba2fc306051e32c2b49dd034ad9a3dbd93a690a17d6658142fec4ac565d9aca2c646257361ea3faf9615fc86cdefce0eab
6
+ metadata.gz: 96fcc2ad2376469b599f715f48f7db5ae2186cfa8ed74241e1c763429e3275031a829fada13de6ae79400515eab1753ecbd7b85af77296617272882fbdec2005
7
+ data.tar.gz: 05a88be6dfffc0122058470311da6fd665ba04e3a6840deb81a8697da4c2d735028c4a62087bd2ee91b9ef1f4961102c65edd4c132088de50e8bb3a52b3857fd
data/gem-src.gemspec CHANGED
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
 
5
5
  Gem::Specification.new do |gem|
6
6
  gem.name = "gem-src"
7
- gem.version = '0.6.1'
7
+ gem.version = '0.6.3'
8
8
  gem.authors = ["Akira Matsuda"]
9
9
  gem.email = ["ronnie@dio.jp"]
10
10
  gem.description = 'Gem.post_install { `git clone gem_source src` }'
@@ -54,11 +54,11 @@ module Gem
54
54
  end
55
55
 
56
56
  def source_code_uri
57
- api[/^source_code_uri: (.*)$/, 1]
57
+ api_uri_for('source_code')
58
58
  end
59
59
 
60
60
  def homepage_uri
61
- api[/^homepage_uri: (.*)$/, 1]
61
+ api_uri_for('homepage')
62
62
  end
63
63
 
64
64
  def github_organization_uri(name)
@@ -91,6 +91,11 @@ module Gem
91
91
  git_clone(github_url(homepage_uri)) ||
92
92
  git_clone(github_organization_uri(installer.spec.name))
93
93
  end
94
+
95
+ def api_uri_for(key)
96
+ uri = api[Regexp.new("^#{key}_uri: (.*)$"), 1]
97
+ uri =~ /\Ahttps?:\/\// ? uri : nil
98
+ end
94
99
  end
95
100
  end
96
101
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gem-src
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.1
4
+ version: 0.6.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Akira Matsuda
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-06-03 00:00:00.000000000 Z
11
+ date: 2014-08-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec