public_suffix 3.0.3 → 4.0.6

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,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: db25a54fc0b67b7906c186324185f71d08f848e0f520b6e7b591429505eaf7bc
4
- data.tar.gz: ae070e1611d89bfa664188ccca18606c0a482cd0e09a2ccf7d73343575ee5f9d
3
+ metadata.gz: 48a2adc85da4aa3f989df90aab4b788c33f029def5daa425e1c78f2f996f457e
4
+ data.tar.gz: 6b8fd93652f1eb725867dfc646f76f42524e3efecd758439ca0337e5717f7182
5
5
  SHA512:
6
- metadata.gz: ddf6ed9d0fb235f8747d16a8861fb0427ce57f1ccf33e607bab3406fabbfea44b6ef670fd0bb49f3d1f12a8e1fdae2c68285d4e4ce09dd6d4bd7508f0e94ec41
7
- data.tar.gz: ed737ad2c839c513389ea2cdb304eb318420dc7fd383713d156d0dd8684db12700a45e5dba1f5616b7dec38deec5526477f4c3502447cef87c3bcc49958eb1ba
6
+ metadata.gz: 52c6c74121231ef5d99e165eec0fb460e4c286cbf0cf06fbe89a98272bc7ff2de68a7cf464676074f3851a0a4e2d7f842e3e34f7ddde32f480d2474bc6dd62c9
7
+ data.tar.gz: 96cd0e0294cc31ca0176362938022d65782deec59ecb4e606119481a09e1906cccc05203ae4ba7ddb5bb20a2915cbea99d696c47335f250b1db8d512b41499d1
@@ -0,0 +1,12 @@
1
+ # These are supported funding model platforms
2
+
3
+ github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
4
+ patreon: # Replace with a single Patreon username
5
+ open_collective: # Replace with a single Open Collective username
6
+ ko_fi: # Replace with a single Ko-fi username
7
+ tidelift: "rubygems/public_suffix"
8
+ community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9
+ liberapay: # Replace with a single Liberapay username
10
+ issuehunt: # Replace with a single IssueHunt username
11
+ otechie: # Replace with a single Otechie username
12
+ custom: # Replace with a single custom sponsorship URL
@@ -0,0 +1,36 @@
1
+ name: Tests
2
+
3
+ on:
4
+ push:
5
+ branches: [ master ]
6
+ pull_request:
7
+ branches: [ master ]
8
+
9
+ jobs:
10
+
11
+ build:
12
+ strategy:
13
+ matrix:
14
+ ruby-version:
15
+ # - "2.3"
16
+ - "2.4"
17
+ - "2.5"
18
+ - "2.6"
19
+ - "2.7"
20
+ platform: [ubuntu-latest]
21
+
22
+ runs-on: ${{ matrix.platform }}
23
+ steps:
24
+
25
+ - uses: actions/checkout@v2
26
+
27
+ - name: Set up Ruby
28
+ uses: ruby/setup-ruby@v1
29
+ with:
30
+ ruby-version: ${{ matrix.ruby-version }}
31
+
32
+ - name: Install dependencies
33
+ run: bundle install
34
+
35
+ - name: Run tests
36
+ run: bundle exec rake
data/.gitignore CHANGED
@@ -1,11 +1,8 @@
1
1
  # Bundler
2
- .bundle
3
- Gemfile.lock
4
- pkg/*
5
-
6
- # Rubinius
7
- *.rbc
2
+ /.bundle
3
+ /Gemfile.lock
4
+ /pkg/*
8
5
 
9
6
  # YARD
10
- .yardoc
11
- yardoc/
7
+ /.yardoc
8
+ /yardoc/
@@ -1,5 +1,5 @@
1
1
  inherit_from:
2
- - .rubocop_defaults.yml
2
+ - .rubocop_opinionated.yml
3
3
 
4
4
  AllCops:
5
5
  Exclude:
@@ -24,7 +24,7 @@ Style/ClassAndModuleChildren:
24
24
  - 'test/**/*_test.rb'
25
25
 
26
26
  # Dear Rubocop, I don't want to use String#strip_heredoc
27
- Layout/IndentHeredoc:
27
+ Layout/HeredocIndentation:
28
28
  Enabled: false
29
29
 
30
30
  Style/WordArray:
@@ -5,6 +5,15 @@ AllCops:
5
5
  # Exclude vendored folders
6
6
  - 'tmp/**/*'
7
7
  - 'vendor/**/*'
8
+ NewCops: enable
9
+
10
+ # [codesmell]
11
+ Layout/LineLength:
12
+ Enabled: false
13
+ Exclude:
14
+ - 'spec/**/*_spec.rb'
15
+ - 'test/**/*_test.rb'
16
+ Max: 100
8
17
 
9
18
  # [codesmell]
10
19
  Metrics/AbcSize:
@@ -31,14 +40,6 @@ Metrics/ClassLength:
31
40
  - 'spec/**/*_spec.rb'
32
41
  - 'test/**/*_test.rb'
33
42
 
34
- # [codesmell]
35
- Metrics/LineLength:
36
- Enabled: false
37
- Exclude:
38
- - 'spec/**/*_spec.rb'
39
- - 'test/**/*_test.rb'
40
- Max: 100
41
-
42
43
  # [codesmell]
43
44
  Metrics/MethodLength:
44
45
  Enabled: false
@@ -63,11 +64,6 @@ Metrics/ParameterLists:
63
64
  Metrics/PerceivedComplexity:
64
65
  Enabled: false
65
66
 
66
- # [codesmell]
67
- # I don't really get the point of this cop.
68
- Performance/RedundantMerge:
69
- Enabled: false
70
-
71
67
  # Do not use "and" or "or" in conditionals, but for readability we can use it
72
68
  # to chain executions. Just beware of operator order.
73
69
  Style/AndOr:
@@ -110,32 +106,6 @@ Style/FormatString:
110
106
  Style/FormatStringToken:
111
107
  Enabled: false
112
108
 
113
- # Prefer the latest Hash syntax
114
- Style/HashSyntax:
115
- Exclude:
116
- # But Rakefiles generally have some definition like
117
- # :default => :test
118
- # that looks nicer with the old rocket syntax.
119
- - 'Rakefile'
120
-
121
- Style/RescueStandardError:
122
- Enabled: false
123
-
124
- # Array indentation should be considered like MultilineMethodCallIndentation indentation
125
- # and use 4 spaces instead of 2.
126
- Layout/IndentArray:
127
- IndentationWidth: 4
128
-
129
- # Hash indentation should be considered like MultilineMethodCallIndentation indentation
130
- # and use 4 spaces instead of 2.
131
- Layout/IndentHash:
132
- IndentationWidth: 4
133
-
134
- # Multi-line differs from standard indentation, they are indented twice.
135
- Layout/MultilineMethodCallIndentation:
136
- EnforcedStyle: indented
137
- IndentationWidth: 4
138
-
139
109
  # unless is not always cool.
140
110
  Style/NegatedIf:
141
111
  Enabled: false
@@ -150,6 +120,9 @@ Style/PercentLiteralDelimiters:
150
120
  Style/RescueModifier:
151
121
  Enabled: false
152
122
 
123
+ Style/SymbolArray:
124
+ EnforcedStyle: brackets
125
+
153
126
  # Sorry, but using trailing spaces helps readability.
154
127
  #
155
128
  # %w( foo bar )
@@ -1,16 +1,15 @@
1
1
  language: ruby
2
2
 
3
3
  rvm:
4
- - 2.1
5
- - 2.2
6
- - 2.3
4
+ # - 2.3
7
5
  - 2.4
8
6
  - 2.5
9
- - jruby-9.1.5.0
7
+ - 2.6
8
+ - 2.7
10
9
  - ruby-head
11
10
 
12
11
  env:
13
- - COVERALL=1
12
+ - COVERAGE=1
14
13
 
15
14
  cache:
16
15
  - bundler
@@ -18,8 +17,7 @@ cache:
18
17
  matrix:
19
18
  allow_failures:
20
19
  - rvm: ruby-head
21
- - rvm: jruby-9.1.0.0
22
20
 
23
21
  before_install:
24
- - rvm get latest
22
+ - gem update --system
25
23
  - gem install bundler
@@ -1,23 +1,89 @@
1
1
  # Changelog
2
2
 
3
+ This project uses [Semantic Versioning 2.0.0](https://semver.org/).
3
4
 
4
- #### Release 3.0.3
5
+
6
+ ## 4.0.6
7
+
8
+ ### Changed
9
+
10
+ - Updated definitions.
11
+
12
+
13
+ ## 4.0.5
14
+
15
+ ### Changed
16
+
17
+ - Updated definitions.
18
+
19
+
20
+ ## 4.0.4
21
+
22
+ ### Changed
23
+
24
+ - Updated definitions.
25
+
26
+
27
+ ## 4.0.3
28
+
29
+ ### Fixed
30
+
31
+ - Fixed 2.7 deprecations and warnings (GH-167). [Thanks @BrianHawley]
32
+
33
+
34
+ ## 4.0.2
35
+
36
+ ### Changed
37
+
38
+ - Updated definitions.
39
+
40
+
41
+ ## 4.0.1
42
+
43
+ ### Changed
44
+
45
+ - Updated definitions.
46
+
47
+
48
+ ## 4.0.0
49
+
50
+ ### Changed
51
+
52
+ - Minimum Ruby version is 2.3
53
+
54
+
55
+ ## Release 3.1.1
56
+
57
+ - CHANGED: Updated definitions.
58
+ - CHANGED: Rolled back support for Ruby 2.3 (GH-161, GH-162)
59
+
60
+ IMPORTANT: 3.x is the latest version compatible with Ruby 2.1 and Ruby 2.2.
61
+
62
+
63
+ ## Release 3.1.0
64
+
65
+ - CHANGED: Updated definitions.
66
+ - CHANGED: Minimum Ruby version is 2.3
67
+ - CHANGED: Upgraded to Bundler 2.x
68
+
69
+
70
+ ## Release 3.0.3
5
71
 
6
72
  - CHANGED: Updated definitions.
7
73
 
8
74
 
9
- #### Release 3.0.2
75
+ ## Release 3.0.2
10
76
 
11
77
  - CHANGED: Updated definitions.
12
78
 
13
79
 
14
- #### Release 3.0.1
80
+ ## Release 3.0.1
15
81
 
16
82
  - CHANGED: Updated definitions.
17
83
  - CHANGED: Improve performance and avoid allocation (GH-146). [Thanks @robholland]
18
84
 
19
85
 
20
- #### Release 3.0.0
86
+ ## Release 3.0.0
21
87
 
22
88
  This new version includes a major redesign of the library internals, with the goal to drastically
23
89
  improve the lookup time while reducing storage space.
@@ -34,35 +100,35 @@ and/or removed. You can find more information at GH-133.
34
100
  - CHANGED: Redesigned internal list storage and lookup algorithm to achieve O(1) lookup time (see GH-133).
35
101
 
36
102
 
37
- #### Release 2.0.5
103
+ ## Release 2.0.5
38
104
 
39
105
  - CHANGED: Updated definitions.
40
106
  - CHANGED: Initialization performance improvements (GH-128). [Thanks @casperisfine]
41
107
 
42
108
 
43
- #### Release 2.0.4
109
+ ## Release 2.0.4
44
110
 
45
111
  - FIXED: Fix a bug that caused the GEM to be published with the wrong version number in the gemspec (GH-121).
46
112
 
47
113
  - CHANGED: Updated definitions.
48
114
 
49
115
 
50
- #### Release 2.0.3
116
+ ## Release 2.0.3
51
117
 
52
118
  - CHANGED: Updated definitions.
53
119
 
54
120
 
55
- #### Release 2.0.2
121
+ ## Release 2.0.2
56
122
 
57
123
  - CHANGED: Updated definitions.
58
124
 
59
125
 
60
- #### Release 2.0.1
126
+ ## Release 2.0.1
61
127
 
62
128
  - FIXED: Fix bug that prevented .valid? to reset the default rule
63
129
 
64
130
 
65
- #### Release 2.0.0
131
+ ## Release 2.0.0
66
132
 
67
133
  - NEW: Added PublicSuffix.domain # => sld.tld
68
134
  - NEW: Added the ability to disable the use of private domains either at runtime, in addition to the ability to not load the private domains section when reading the list (`private_domains: false`). This feature also superseded the `private_domains` class-level attribute, that is no longer available.
@@ -79,97 +145,97 @@ and/or removed. You can find more information at GH-133.
79
145
  - REMOVED: Removed futile utility helpers such as `Domain#rule`, `Domain#is_a_domain?`, `Domain#is_a_subdomain?`, `Domain#valid?`. You can easily obtain the same result by having a custom method that reconstructs the logic, and/or calling `PublicSuffix.{domain|parse}(domain.to_s)`.
80
146
 
81
147
 
82
- #### Release 1.5.3
148
+ ## Release 1.5.3
83
149
 
84
150
  - FIXED: Don't duplicate rule indices when creating index (GH-77). [Thanks @ags]
85
151
 
86
152
  - CHANGED: Updated definitions.
87
153
 
88
154
 
89
- #### Release 1.5.2
155
+ ## Release 1.5.2
90
156
 
91
157
  - CHANGED: Updated definitions.
92
158
 
93
159
 
94
- #### Release 1.5.1
160
+ ## Release 1.5.1
95
161
 
96
162
  - FIXED: Ignore case for parsing and validating (GH-62)
97
163
 
98
164
  - CHANGED: Updated definitions.
99
165
 
100
166
 
101
- #### Release 1.5.0
167
+ ## Release 1.5.0
102
168
 
103
169
  - CHANGED: Dropped support for Ruby < 2.0
104
170
 
105
171
  - CHANGED: Updated definitions.
106
172
 
107
173
 
108
- #### Release 1.4.6
174
+ ## Release 1.4.6
109
175
 
110
176
  - CHANGED: Updated definitions.
111
177
 
112
178
 
113
- #### Release 1.4.5
179
+ ## Release 1.4.5
114
180
 
115
181
  - CHANGED: Updated definitions.
116
182
 
117
183
 
118
- #### Release 1.4.4
184
+ ## Release 1.4.4
119
185
 
120
186
  - CHANGED: Updated definitions.
121
187
 
122
188
 
123
- #### Release 1.4.3
189
+ ## Release 1.4.3
124
190
 
125
191
  - CHANGED: Updated definitions.
126
192
 
127
193
 
128
- #### Release 1.4.2
194
+ ## Release 1.4.2
129
195
 
130
196
  - CHANGED: Updated definitions.
131
197
 
132
198
 
133
- #### Release 1.4.1
199
+ ## Release 1.4.1
134
200
 
135
201
  - CHANGED: Updated definitions.
136
202
 
137
203
 
138
- #### Release 1.4.0
204
+ ## Release 1.4.0
139
205
 
140
206
  - CHANGED: Moved the definitions in the lib folder.
141
207
 
142
208
  - CHANGED: Updated definitions.
143
209
 
144
210
 
145
- #### Release 1.3.3
211
+ ## Release 1.3.3
146
212
 
147
213
  - CHANGED: Updated definitions.
148
214
 
149
215
 
150
- #### Release 1.3.2
216
+ ## Release 1.3.2
151
217
 
152
218
  - CHANGED: Updated definitions.
153
219
 
154
220
 
155
- #### Release 1.3.1
221
+ ## Release 1.3.1
156
222
 
157
223
  - CHANGED: Updated definitions.
158
224
 
159
225
 
160
- #### Release 1.3.0
226
+ ## Release 1.3.0
161
227
 
162
228
  - NEW: Ability to skip Private Domains (GH-28). [Thanks @rb2k]
163
229
 
164
230
  - CHANGED: Updated definitions.
165
231
 
166
232
 
167
- #### Release 1.2.1
233
+ ## Release 1.2.1
168
234
 
169
235
  - CHANGED: Updated definitions.
170
236
 
171
237
 
172
- #### Release 1.2.0
238
+ ## Release 1.2.0
173
239
 
174
240
  - NEW: Allow a custom List on `PublicSuffix.parse` (GH-26). [Thanks @itspriddle]
175
241
 
@@ -178,22 +244,22 @@ and/or removed. You can find more information at GH-133.
178
244
  - CHANGED: Updated definitions.
179
245
 
180
246
 
181
- #### Release 1.1.3
247
+ ## Release 1.1.3
182
248
 
183
249
  - CHANGED: Updated definitions.
184
250
 
185
251
 
186
- #### Release 1.1.2
252
+ ## Release 1.1.2
187
253
 
188
254
  - CHANGED: Updated definitions.
189
255
 
190
256
 
191
- #### Release 1.1.1
257
+ ## Release 1.1.1
192
258
 
193
259
  - CHANGED: Updated definitions.
194
260
 
195
261
 
196
- #### Release 1.1.0
262
+ ## Release 1.1.0
197
263
 
198
264
  - FIXED: #valid? and #parse consider URIs as valid domains (GH-15)
199
265
 
@@ -202,17 +268,17 @@ and/or removed. You can find more information at GH-133.
202
268
  - CHANGED: Removed deprecatd PublicSuffixService::RuleList.
203
269
 
204
270
 
205
- #### Release 1.0.0
271
+ ## Release 1.0.0
206
272
 
207
273
  - CHANGED: Updated definitions.
208
274
 
209
275
 
210
- #### Release 1.0.0.rc1
276
+ ## Release 1.0.0.rc1
211
277
 
212
278
  The library is now known as PublicSuffix.
213
279
 
214
280
 
215
- #### Release 0.9.1
281
+ ## Release 0.9.1
216
282
 
217
283
  - CHANGED: Renamed PublicSuffixService::RuleList to PublicSuffixService::List.
218
284
 
@@ -223,20 +289,20 @@ The library is now known as PublicSuffix.
223
289
  - CHANGED: Updated definitions.
224
290
 
225
291
 
226
- #### Release 0.9.0
292
+ ## Release 0.9.0
227
293
 
228
294
  - CHANGED: Minimum Ruby version increased to Ruby 1.8.7.
229
295
 
230
296
  - CHANGED: rake/gempackagetask is deprecated. Use rubygems/package_task instead.
231
297
 
232
298
 
233
- #### Release 0.8.4
299
+ ## Release 0.8.4
234
300
 
235
301
  - FIXED: Reverted bugfix for issue #12 for Ruby 1.8.6.
236
302
  This is the latest version compatible with Ruby 1.8.6.
237
303
 
238
304
 
239
- #### Release 0.8.3
305
+ ## Release 0.8.3
240
306
 
241
307
  - FIXED: Fixed ArgumentError: invalid byte sequence in US-ASCII with Ruby 1.9.2 (#12).
242
308
 
@@ -245,7 +311,7 @@ The library is now known as PublicSuffix.
245
311
  - CHANGED: Renamed definitions.txt to definitions.dat.
246
312
 
247
313
 
248
- #### Release 0.8.2
314
+ ## Release 0.8.2
249
315
 
250
316
  - NEW: Added support for rubygems-test.
251
317
 
@@ -254,19 +320,19 @@ The library is now known as PublicSuffix.
254
320
  - CHANGED: Updated definitions.
255
321
 
256
322
 
257
- #### Release 0.8.1
323
+ ## Release 0.8.1
258
324
 
259
325
  - FIXED: The files in the release 0.8.0 have wrong permission 600 and can't be loaded (#10).
260
326
 
261
327
 
262
- #### Release 0.8.0
328
+ ## Release 0.8.0
263
329
 
264
330
  - CHANGED: Update public suffix list to d1a5599b49fa 2010-10-25 15:10 +0100 (#9)
265
331
 
266
332
  - NEW: Add support for Fully Qualified Domain Names (#7)
267
333
 
268
334
 
269
- #### Release 0.7.0
335
+ ## Release 0.7.0
270
336
 
271
337
  - CHANGED: Using YARD to document the code instead of RDoc.
272
338
 
@@ -275,7 +341,7 @@ The library is now known as PublicSuffix.
275
341
  - FIXED: PublicSuffixService.valid? should return false if the domain is not defined or not allowed (#4, #5)
276
342
 
277
343
 
278
- #### Release 0.6.0
344
+ ## Release 0.6.0
279
345
 
280
346
  - NEW: PublicSuffixService.parse raises DomainNotAllowed when trying to parse a domain name
281
347
  which exists, but is not allowed by the current definition list (#3)
@@ -286,34 +352,34 @@ The library is now known as PublicSuffix.
286
352
  - CHANGED: Renamed PublicSuffixService::InvalidDomain to PublicSuffixService::DomainInvalid
287
353
 
288
354
 
289
- #### Release 0.5.2
355
+ ## Release 0.5.2
290
356
 
291
357
  - CHANGED: Update public suffix list to 248ea690d671 2010-09-16 18:02 +0100
292
358
 
293
359
 
294
- #### Release 0.5.1
360
+ ## Release 0.5.1
295
361
 
296
362
  - CHANGED: Update public suffix list to 14dc66dd53c1 2010-09-15 17:09 +0100
297
363
 
298
364
 
299
- #### Release 0.5.0
365
+ ## Release 0.5.0
300
366
 
301
367
  - CHANGED: Improve documentation for Domain#domain and Domain#subdomain (#1).
302
368
 
303
369
  - CHANGED: Performance improvements (#2).
304
370
 
305
371
 
306
- #### Release 0.4.0
372
+ ## Release 0.4.0
307
373
 
308
374
  - CHANGED: Rename library from DomainName to PublicSuffixService to reduce the probability of name conflicts.
309
375
 
310
376
 
311
- #### Release 0.3.1
377
+ ## Release 0.3.1
312
378
 
313
379
  - Deprecated DomainName library.
314
380
 
315
381
 
316
- #### Release 0.3.0
382
+ ## Release 0.3.0
317
383
 
318
384
  - CHANGED: DomainName#domain and DomainName#subdomain are no longer alias of Domain#sld and Domain#tld.
319
385
 
@@ -324,7 +390,7 @@ The library is now known as PublicSuffix.
324
390
  - CHANGED: Refactoring the entire DomainName API. Removed the internal on-the-fly parsing. Added a bunch of new methods to check and validate the DomainName.
325
391
 
326
392
 
327
- #### Release 0.2.0
393
+ ## Release 0.2.0
328
394
 
329
395
  - NEW: DomainName#valid?
330
396
 
@@ -335,6 +401,6 @@ The library is now known as PublicSuffix.
335
401
  - CHANGED: Make sure RuleList lookup is only performed once.
336
402
 
337
403
 
338
- #### Release 0.1.0
404
+ ## Release 0.1.0
339
405
 
340
406
  - Initial version