restpack_core_service 0.0.13 → 0.0.14
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 085d8a573afa75c5f06c74bba0b3918aafd3129b
|
4
|
+
data.tar.gz: 4fe6d9dd04397852bdc29e76f0564dd18eba588f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 159ef754c4c0857942a1c349cf7d76adfb2454c39a32e6f39778996d13ea843634e9bc70465253ea81b5aa4b7bcc61a00c93c832bff8b848792198b3ba20dfb8
|
7
|
+
data.tar.gz: b3280ff58be5a855357a1b8fdb43dc1b079742701018b01112c92d2ee19bb1ccaa1469c716660d11d151303faa37a649945f32c6a17a41d174da70399491db3c
|
@@ -1,5 +1,3 @@
|
|
1
|
-
require 'public_suffix'
|
2
|
-
|
3
1
|
module Commands::Core::Domain
|
4
2
|
class ByIdentifier < RestPack::Service::Command
|
5
3
|
required do
|
@@ -13,7 +11,7 @@ module Commands::Core::Domain
|
|
13
11
|
def execute
|
14
12
|
identifiers = [
|
15
13
|
inputs[:identifier],
|
16
|
-
|
14
|
+
without_subdomain(identifier)
|
17
15
|
]
|
18
16
|
|
19
17
|
identifiers.reject(&:nil?).each do |identifier|
|
@@ -32,12 +30,8 @@ module Commands::Core::Domain
|
|
32
30
|
|
33
31
|
private
|
34
32
|
|
35
|
-
def
|
36
|
-
|
37
|
-
PublicSuffix.parse(identifier).domain
|
38
|
-
rescue
|
39
|
-
nil
|
40
|
-
end
|
33
|
+
def without_subdomain(identifier)
|
34
|
+
identifier.split('.')[1..-1].join('.')
|
41
35
|
end
|
42
36
|
end
|
43
37
|
end
|
@@ -19,7 +19,6 @@ Gem::Specification.new do |spec|
|
|
19
19
|
spec.require_paths = ["lib"]
|
20
20
|
|
21
21
|
spec.add_dependency "restpack_service"
|
22
|
-
spec.add_dependency "public_suffix", "~> 1.3.1"
|
23
22
|
|
24
23
|
spec.add_development_dependency "bundler", "~> 1.3"
|
25
24
|
spec.add_development_dependency "database_cleaner", "~> 1.0.1"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: restpack_core_service
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.14
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gavin Joyce
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-
|
11
|
+
date: 2013-12-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: restpack_service
|
@@ -24,20 +24,6 @@ dependencies:
|
|
24
24
|
- - '>='
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
|
-
- !ruby/object:Gem::Dependency
|
28
|
-
name: public_suffix
|
29
|
-
requirement: !ruby/object:Gem::Requirement
|
30
|
-
requirements:
|
31
|
-
- - ~>
|
32
|
-
- !ruby/object:Gem::Version
|
33
|
-
version: 1.3.1
|
34
|
-
type: :runtime
|
35
|
-
prerelease: false
|
36
|
-
version_requirements: !ruby/object:Gem::Requirement
|
37
|
-
requirements:
|
38
|
-
- - ~>
|
39
|
-
- !ruby/object:Gem::Version
|
40
|
-
version: 1.3.1
|
41
27
|
- !ruby/object:Gem::Dependency
|
42
28
|
name: bundler
|
43
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -206,7 +192,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
206
192
|
version: '0'
|
207
193
|
requirements: []
|
208
194
|
rubyforge_project:
|
209
|
-
rubygems_version: 2.0.
|
195
|
+
rubygems_version: 2.0.5
|
210
196
|
signing_key:
|
211
197
|
specification_version: 4
|
212
198
|
summary: Applications, Domains and Configurations
|