net_status 0.1.3 → 0.2.0

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.
checksums.yaml CHANGED
@@ -1,15 +1,7 @@
1
1
  ---
2
- !binary "U0hBMQ==":
3
- metadata.gz: !binary |-
4
- MDhjYTA4NTI4ZWQyM2I1MmJkN2UyZTBhMDBiMTNlYTU1NmFiYmEwNA==
5
- data.tar.gz: !binary |-
6
- MjE0ZTgzMDgwYjA5ZGU5ZTZjY2M2YzI0MjAxNTMyOGU3MTA4ZGVlMA==
2
+ SHA1:
3
+ metadata.gz: 8c3d9a1f6e784162ac3380bc9d87ffbc07553fbd
4
+ data.tar.gz: 3161c005d69d6f5471247f8a6758710cb9bf2af9
7
5
  SHA512:
8
- metadata.gz: !binary |-
9
- OThlNmQyMTA3Y2QyOGFmMWRiYTc5MDgxMGY2NTE5MjU2M2JlMjFlNTE4NWQz
10
- OTMzN2QyOTE1YjAxNTY1N2I4NWMxYTE3OTE0ZjQ2YzgxODVlZmUzYTA3ZjMz
11
- YzUxY2RlZmUyYTEzMzk4ZTc1MmRhNWNlMzJhNTkwZmUwMDA0YTE=
12
- data.tar.gz: !binary |-
13
- MzJlY2I1YTY2Y2Q1MTNlNzAwNjViZDA0NzU2NWM5NTY5OTY1NjdiODEwMTcz
14
- YzNlZGVjZWJmNjExN2ZjZGVjNjkzZTg4N2M2MDI0MmYwZDQyYzJhYjcyYzZi
15
- ZTMyYjdlYTQ0MzgzMjllMDY0NmNhNTljNmNkZGY4OWE1OWI4ZjE=
6
+ metadata.gz: 16a7b0336305ede3908c767f35dcb494f9e329b1a912ce68d3a02ab66f4bee53a145d263d6fdf4f33d1733630c3518da525379d34a07b95ef9acd43833ad5f9d
7
+ data.tar.gz: fd07e8a249721184feccd9557ecd1e9e49edcf5245bbdc1578fd2b5c9c8eea6de96b526a67a85fe785649b0f4ecdde8f76c9819ba31f5ff6df2cc3692524236f
@@ -8,7 +8,8 @@ module NetStatus
8
8
  code = net_status[:code]
9
9
  code ||= net_status[:error] if net_status.include? :error
10
10
  net_status[:data] ||= {}
11
- net_status[:message] = I18n.t [:net_status, context, code].join('.'), [:net_status, code].join('.'), **net_status[:data], raise: true rescue nil
11
+ message = (I18n.t [:net_status, context, code].join('.'), [:net_status, code].join('.'), **net_status[:data], raise: true rescue nil)
12
+ net_status[:message] = message if message
12
13
  net_status
13
14
  end
14
15
  end
@@ -1,3 +1,3 @@
1
1
  module NetStatus
2
- VERSION = '0.1.3'
2
+ VERSION = '0.2.0'
3
3
  end
metadata CHANGED
@@ -1,138 +1,130 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: net_status
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexey Igrychev
8
+ - Timofey Kirillov
8
9
  autorequire:
9
10
  bindir: bin
10
11
  cert_chain: []
11
- date: 2016-09-19 00:00:00.000000000 Z
12
+ date: 2017-10-26 00:00:00.000000000 Z
12
13
  dependencies:
13
14
  - !ruby/object:Gem::Dependency
14
15
  name: i18n
15
16
  requirement: !ruby/object:Gem::Requirement
16
17
  requirements:
17
- - - ~>
18
+ - - "~>"
18
19
  - !ruby/object:Gem::Version
19
20
  version: '0.7'
20
21
  type: :runtime
21
22
  prerelease: false
22
23
  version_requirements: !ruby/object:Gem::Requirement
23
24
  requirements:
24
- - - ~>
25
+ - - "~>"
25
26
  - !ruby/object:Gem::Version
26
27
  version: '0.7'
27
28
  - !ruby/object:Gem::Dependency
28
29
  name: bundler
29
30
  requirement: !ruby/object:Gem::Requirement
30
31
  requirements:
31
- - - ~>
32
+ - - "~>"
32
33
  - !ruby/object:Gem::Version
33
34
  version: '1.7'
34
35
  type: :development
35
36
  prerelease: false
36
37
  version_requirements: !ruby/object:Gem::Requirement
37
38
  requirements:
38
- - - ~>
39
+ - - "~>"
39
40
  - !ruby/object:Gem::Version
40
41
  version: '1.7'
41
42
  - !ruby/object:Gem::Dependency
42
43
  name: rake
43
44
  requirement: !ruby/object:Gem::Requirement
44
45
  requirements:
45
- - - ~>
46
+ - - "~>"
46
47
  - !ruby/object:Gem::Version
47
48
  version: '10.0'
48
49
  type: :development
49
50
  prerelease: false
50
51
  version_requirements: !ruby/object:Gem::Requirement
51
52
  requirements:
52
- - - ~>
53
+ - - "~>"
53
54
  - !ruby/object:Gem::Version
54
55
  version: '10.0'
55
56
  - !ruby/object:Gem::Dependency
56
57
  name: rspec
57
58
  requirement: !ruby/object:Gem::Requirement
58
59
  requirements:
59
- - - ~>
60
+ - - "~>"
60
61
  - !ruby/object:Gem::Version
61
62
  version: '3.4'
62
- - - ! '>='
63
+ - - ">="
63
64
  - !ruby/object:Gem::Version
64
65
  version: 3.4.0
65
66
  type: :development
66
67
  prerelease: false
67
68
  version_requirements: !ruby/object:Gem::Requirement
68
69
  requirements:
69
- - - ~>
70
+ - - "~>"
70
71
  - !ruby/object:Gem::Version
71
72
  version: '3.4'
72
- - - ! '>='
73
+ - - ">="
73
74
  - !ruby/object:Gem::Version
74
75
  version: 3.4.0
75
76
  - !ruby/object:Gem::Dependency
76
77
  name: travis
77
78
  requirement: !ruby/object:Gem::Requirement
78
79
  requirements:
79
- - - ~>
80
+ - - "~>"
80
81
  - !ruby/object:Gem::Version
81
82
  version: '1.8'
82
- - - ! '>='
83
+ - - ">="
83
84
  - !ruby/object:Gem::Version
84
85
  version: 1.8.2
85
86
  type: :development
86
87
  prerelease: false
87
88
  version_requirements: !ruby/object:Gem::Requirement
88
89
  requirements:
89
- - - ~>
90
+ - - "~>"
90
91
  - !ruby/object:Gem::Version
91
92
  version: '1.8'
92
- - - ! '>='
93
+ - - ">="
93
94
  - !ruby/object:Gem::Version
94
95
  version: 1.8.2
95
96
  - !ruby/object:Gem::Dependency
96
97
  name: pry
97
98
  requirement: !ruby/object:Gem::Requirement
98
99
  requirements:
99
- - - ! '>='
100
+ - - ">="
100
101
  - !ruby/object:Gem::Version
101
102
  version: 0.10.3
102
- - - <
103
+ - - "<"
103
104
  - !ruby/object:Gem::Version
104
105
  version: '1.0'
105
106
  type: :development
106
107
  prerelease: false
107
108
  version_requirements: !ruby/object:Gem::Requirement
108
109
  requirements:
109
- - - ! '>='
110
+ - - ">="
110
111
  - !ruby/object:Gem::Version
111
112
  version: 0.10.3
112
- - - <
113
+ - - "<"
113
114
  - !ruby/object:Gem::Version
114
115
  version: '1.0'
115
116
  description: Net status return codes.
116
117
  email:
117
118
  - alexey.igrychev@flant.ru
119
+ - timofey.kirillov@flant.com
118
120
  executables: []
119
121
  extensions: []
120
122
  extra_rdoc_files: []
121
123
  files:
122
- - .gitignore
123
- - .travis.yml
124
- - Gemfile
125
- - Gemfile.lock
126
- - LICENSE.txt
127
- - README.md
128
- - Rakefile
129
124
  - lib/net_status.rb
130
125
  - lib/net_status/exception.rb
131
126
  - lib/net_status/hash.rb
132
127
  - lib/net_status/version.rb
133
- - net_status.gemspec
134
- - spec/net_status_spec.rb
135
- - spec/spec_helper.rb
136
128
  homepage: https://github.com/flant/net_status
137
129
  licenses:
138
130
  - MIT
@@ -143,20 +135,18 @@ require_paths:
143
135
  - lib
144
136
  required_ruby_version: !ruby/object:Gem::Requirement
145
137
  requirements:
146
- - - ! '>='
138
+ - - ">="
147
139
  - !ruby/object:Gem::Version
148
140
  version: '0'
149
141
  required_rubygems_version: !ruby/object:Gem::Requirement
150
142
  requirements:
151
- - - ! '>='
143
+ - - ">="
152
144
  - !ruby/object:Gem::Version
153
- version: '0'
145
+ version: 2.5.0
154
146
  requirements: []
155
147
  rubyforge_project:
156
- rubygems_version: 2.4.5
148
+ rubygems_version: 2.6.14
157
149
  signing_key:
158
150
  specification_version: 4
159
151
  summary: Net status return codes
160
- test_files:
161
- - spec/net_status_spec.rb
162
- - spec/spec_helper.rb
152
+ test_files: []
data/.gitignore DELETED
@@ -1,10 +0,0 @@
1
- /.bundle/
2
- /.yardoc
3
- /_yardoc/
4
- /coverage/
5
- /doc/
6
- /pkg/
7
- /spec/reports/
8
- /tmp/
9
- /.idea
10
- /net_status*.gem
@@ -1,11 +0,0 @@
1
- language: ruby
2
- rvm:
3
- - 2.2.1
4
- deploy:
5
- provider: rubygems
6
- api_key:
7
- secure: ooI10ZieDzVtg3aIPN3v7HZrJsd7nOFOZ9tH0+l4p3+Nrdvtt+ycAEo5tsPk27/JY2rjkxBDFgZ5GWRlrx5Ls9Px2sGqzpf9FM9T5mM6NrgmctfGPxajAd6OybeCrp+K6wG0F/2GLINd6uoju9yviGSEyIAsN4IhU49I27Je04wwJewiC+pAtesIsaGbCJMQ9Y6XAAHETms6mv7Vnm+jVlpVm2jZIgRQBRWfZdVBjvqlP/RZrRYvXGp4Th7wAJRz4d93UlvyE4xYkPBWNWBddnMyyhWQIjy2yBQ+PF1lYVehmrkhj8lFjn8AxZYwuAjijeRuhiCCEB9kacrLm6xkkDJ4UXd383vg5gS4yCp1V6u3dAvsl4sh56coM0c8gtDZG0o7oSMvRSV1W4Xw0KIIM7JVCn1DDGYD7Mlmx+QDOGI9YQ62AioHKfoAzARwq1wB5JjjOnI/lDkHqGbswC2vHX285+t1Ve9/bu69xtMJxdgij0c//V5IaQJitSd+X5eS+t7omQC/YorBu1MletOan8mj0kSu7nFUlCelbwxe5JGvykQFShvr5y9EGCIb/cp2EcfoYvO7kqsexPcEAkE81qygQRqFnFtuNF/2pxv808PGyNAW+gb50TE7YnCNFk6VL5OD1vKfafSYTBqzsZafHSaAEyiPF+1qUI0qylv2LPU=
8
- gem: net_status
9
- on:
10
- tags: true
11
- repo: flant/net_status
data/Gemfile DELETED
@@ -1,2 +0,0 @@
1
- source 'https://rubygems.org'
2
- gemspec
@@ -1,85 +0,0 @@
1
- PATH
2
- remote: .
3
- specs:
4
- net_status (0.1.3)
5
- i18n (~> 0.7)
6
-
7
- GEM
8
- remote: https://rubygems.org/
9
- specs:
10
- addressable (2.4.0)
11
- backports (3.6.8)
12
- coderay (1.1.1)
13
- diff-lcs (1.2.5)
14
- ethon (0.9.0)
15
- ffi (>= 1.3.0)
16
- faraday (0.9.2)
17
- multipart-post (>= 1.2, < 3)
18
- faraday_middleware (0.10.0)
19
- faraday (>= 0.7.4, < 0.10)
20
- ffi (1.9.10)
21
- gh (0.14.0)
22
- addressable
23
- backports
24
- faraday (~> 0.8)
25
- multi_json (~> 1.0)
26
- net-http-persistent (>= 2.7)
27
- net-http-pipeline
28
- highline (1.7.8)
29
- i18n (0.7.0)
30
- json (1.8.3)
31
- launchy (2.4.3)
32
- addressable (~> 2.3)
33
- method_source (0.8.2)
34
- multi_json (1.11.3)
35
- multipart-post (2.0.0)
36
- net-http-persistent (2.9.4)
37
- net-http-pipeline (1.0.1)
38
- pry (0.10.3)
39
- coderay (~> 1.1.0)
40
- method_source (~> 0.8.1)
41
- slop (~> 3.4)
42
- pusher-client (0.6.2)
43
- json
44
- websocket (~> 1.0)
45
- rake (10.5.0)
46
- rspec (3.4.0)
47
- rspec-core (~> 3.4.0)
48
- rspec-expectations (~> 3.4.0)
49
- rspec-mocks (~> 3.4.0)
50
- rspec-core (3.4.4)
51
- rspec-support (~> 3.4.0)
52
- rspec-expectations (3.4.0)
53
- diff-lcs (>= 1.2.0, < 2.0)
54
- rspec-support (~> 3.4.0)
55
- rspec-mocks (3.4.1)
56
- diff-lcs (>= 1.2.0, < 2.0)
57
- rspec-support (~> 3.4.0)
58
- rspec-support (3.4.1)
59
- slop (3.6.0)
60
- travis (1.8.2)
61
- backports
62
- faraday (~> 0.9)
63
- faraday_middleware (~> 0.9, >= 0.9.1)
64
- gh (~> 0.13)
65
- highline (~> 1.6)
66
- launchy (~> 2.1)
67
- pusher-client (~> 0.4)
68
- typhoeus (~> 0.6, >= 0.6.8)
69
- typhoeus (0.8.0)
70
- ethon (>= 0.8.0)
71
- websocket (1.2.3)
72
-
73
- PLATFORMS
74
- ruby
75
-
76
- DEPENDENCIES
77
- bundler (~> 1.7)
78
- net_status!
79
- pry (>= 0.10.3, < 1.0)
80
- rake (~> 10.0)
81
- rspec (~> 3.4, >= 3.4.0)
82
- travis (~> 1.8, >= 1.8.2)
83
-
84
- BUNDLED WITH
85
- 1.12.5
@@ -1,22 +0,0 @@
1
- Copyright (c) 2016 Alexey Igrychev
2
-
3
- MIT License
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining
6
- a copy of this software and associated documentation files (the
7
- "Software"), to deal in the Software without restriction, including
8
- without limitation the rights to use, copy, modify, merge, publish,
9
- distribute, sublicense, and/or sell copies of the Software, and to
10
- permit persons to whom the Software is furnished to do so, subject to
11
- the following conditions:
12
-
13
- The above copyright notice and this permission notice shall be
14
- included in all copies or substantial portions of the Software.
15
-
16
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
- EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
- NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
- LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
- OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
- WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md DELETED
@@ -1,27 +0,0 @@
1
- # NetStatus
2
-
3
- Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/net_status`. To experiment with that code, run `bin/console` for an interactive prompt.
4
-
5
- TODO: Delete this and the text above, and describe your gem
6
-
7
- ## Installation
8
-
9
- Add this line to your application's Gemfile:
10
-
11
- ```ruby
12
- gem 'net_status'
13
- ```
14
-
15
- And then execute:
16
-
17
- $ bundle
18
-
19
- Or install it yourself as:
20
-
21
- $ gem install net_status
22
-
23
- ## Usage
24
-
25
- TODO: Write usage instructions here
26
-
27
-
data/Rakefile DELETED
@@ -1,6 +0,0 @@
1
- require 'bundler/gem_tasks'
2
- require 'rspec/core/rake_task'
3
-
4
- RSpec::Core::RakeTask.new(:spec)
5
-
6
- task default: :spec
@@ -1,27 +0,0 @@
1
- lib = File.expand_path('../lib', __FILE__)
2
- $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
3
- require 'net_status/version'
4
-
5
- Gem::Specification.new do |spec|
6
- spec.name = "net_status"
7
- spec.version = NetStatus::VERSION
8
- spec.authors = ["Alexey Igrychev"]
9
- spec.email = ["alexey.igrychev@flant.ru"]
10
- spec.summary = "Net status return codes"
11
- spec.description = "#{spec.summary}."
12
- spec.license = "MIT"
13
- spec.homepage = "https://github.com/flant/net_status"
14
-
15
- spec.files = `git ls-files -z`.split("\x0")
16
- spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
17
- spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
18
- spec.require_paths = ["lib"]
19
-
20
- spec.add_dependency 'i18n', '~> 0.7'
21
-
22
- spec.add_development_dependency 'bundler', '~> 1.7'
23
- spec.add_development_dependency 'rake', '~> 10.0'
24
- spec.add_development_dependency 'rspec', '~> 3.4', '>= 3.4.0'
25
- spec.add_development_dependency 'travis', '~> 1.8', '>= 1.8.2'
26
- spec.add_development_dependency 'pry', '>= 0.10.3', '< 1.0'
27
- end
@@ -1,7 +0,0 @@
1
- require 'spec_helper'
2
-
3
- describe NetStatus do
4
- it 'has a version number' do
5
- expect(NetStatus::VERSION).not_to be nil
6
- end
7
- end
@@ -1,5 +0,0 @@
1
- require 'bundler/setup'
2
-
3
- Bundler.setup
4
-
5
- require 'net_status'