ruby-link-checker 0.3.0 → 0.5.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 (86) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/coverage.yml +24 -0
  3. data/.github/workflows/danger-comment.yml +17 -0
  4. data/.github/workflows/danger.yml +12 -0
  5. data/.github/workflows/lint.yml +20 -0
  6. data/.github/workflows/release.yml +14 -0
  7. data/.github/workflows/test.yml +25 -0
  8. data/.gitignore +6 -0
  9. data/.rspec +2 -0
  10. data/.rubocop.yml +26 -0
  11. data/.rubocop_todo.yml +332 -0
  12. data/AGENTS.md +23 -0
  13. data/CHANGELOG.md +27 -0
  14. data/CONTRIBUTING.md +4 -0
  15. data/Dangerfile +2 -0
  16. data/Gemfile +5 -1
  17. data/README.md +151 -7
  18. data/RELEASING.md +17 -40
  19. data/Rakefile +8 -0
  20. data/benchmarks/check.rb +27 -20
  21. data/lib/ruby-link-checker/async/http/checker.rb +118 -0
  22. data/lib/ruby-link-checker/async/http/config.rb +39 -0
  23. data/lib/ruby-link-checker/async/http/result.rb +85 -0
  24. data/lib/ruby-link-checker/async/http.rb +3 -0
  25. data/lib/ruby-link-checker/cache.rb +101 -0
  26. data/lib/ruby-link-checker/callbacks.rb +2 -2
  27. data/lib/ruby-link-checker/checker.rb +76 -4
  28. data/lib/ruby-link-checker/config.rb +64 -0
  29. data/lib/ruby-link-checker/errors/connection_error.rb +23 -0
  30. data/lib/ruby-link-checker/errors/redirect_limit_error.rb +15 -0
  31. data/lib/ruby-link-checker/errors.rb +2 -0
  32. data/lib/ruby-link-checker/net/http/checker.rb +4 -1
  33. data/lib/ruby-link-checker/net/http/result.rb +4 -0
  34. data/lib/ruby-link-checker/result.rb +25 -0
  35. data/lib/ruby-link-checker/task.rb +2 -0
  36. data/lib/ruby-link-checker/tasks.rb +43 -7
  37. data/lib/ruby-link-checker/typhoeus/hydra/checker.rb +29 -6
  38. data/lib/ruby-link-checker/typhoeus/hydra/result.rb +4 -0
  39. data/lib/ruby-link-checker/version.rb +1 -1
  40. data/lib/ruby-link-checker.rb +2 -0
  41. data/ruby-link-checker.gemspec +3 -2
  42. data/spec/ruby-link-checker/async/http/checker_spec.rb +184 -0
  43. data/spec/ruby-link-checker/callbacks_spec.rb +33 -0
  44. data/spec/ruby-link-checker/checker_spec.rb +89 -2
  45. data/spec/ruby-link-checker/config_spec.rb +6 -0
  46. data/spec/ruby-link-checker/errors/redirect_loop_error_spec.rb +18 -0
  47. data/spec/ruby-link-checker/net/http/checker_spec.rb +32 -0
  48. data/spec/ruby-link-checker/result_error_spec.rb +34 -0
  49. data/spec/ruby-link-checker/result_spec.rb +41 -0
  50. data/spec/ruby-link-checker/task_spec.rb +20 -0
  51. data/spec/ruby-link-checker/tasks_spec.rb +91 -0
  52. data/spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb +116 -3
  53. data/spec/spec_helper.rb +3 -1
  54. data/spec/support/link_checker.rb +267 -3
  55. metadata +42 -35
  56. data/Gemfile.lock +0 -215
  57. data/coverage/assets/0.13.1/DataTables-1.10.20/images/sort_asc.png +0 -0
  58. data/coverage/assets/0.13.1/DataTables-1.10.20/images/sort_asc_disabled.png +0 -0
  59. data/coverage/assets/0.13.1/DataTables-1.10.20/images/sort_both.png +0 -0
  60. data/coverage/assets/0.13.1/DataTables-1.10.20/images/sort_desc.png +0 -0
  61. data/coverage/assets/0.13.1/DataTables-1.10.20/images/sort_desc_disabled.png +0 -0
  62. data/coverage/assets/0.13.1/application.css +0 -1
  63. data/coverage/assets/0.13.1/application.js +0 -7
  64. data/coverage/assets/0.13.1/colorbox/border.png +0 -0
  65. data/coverage/assets/0.13.1/colorbox/controls.png +0 -0
  66. data/coverage/assets/0.13.1/colorbox/loading.gif +0 -0
  67. data/coverage/assets/0.13.1/colorbox/loading_background.png +0 -0
  68. data/coverage/assets/0.13.1/favicon_green.png +0 -0
  69. data/coverage/assets/0.13.1/favicon_red.png +0 -0
  70. data/coverage/assets/0.13.1/favicon_yellow.png +0 -0
  71. data/coverage/assets/0.13.1/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
  72. data/coverage/assets/0.13.1/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
  73. data/coverage/assets/0.13.1/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
  74. data/coverage/assets/0.13.1/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
  75. data/coverage/assets/0.13.1/images/ui-bg_glass_75_dadada_1x400.png +0 -0
  76. data/coverage/assets/0.13.1/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
  77. data/coverage/assets/0.13.1/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
  78. data/coverage/assets/0.13.1/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
  79. data/coverage/assets/0.13.1/images/ui-icons_222222_256x240.png +0 -0
  80. data/coverage/assets/0.13.1/images/ui-icons_2e83ff_256x240.png +0 -0
  81. data/coverage/assets/0.13.1/images/ui-icons_454545_256x240.png +0 -0
  82. data/coverage/assets/0.13.1/images/ui-icons_888888_256x240.png +0 -0
  83. data/coverage/assets/0.13.1/images/ui-icons_cd0a0a_256x240.png +0 -0
  84. data/coverage/assets/0.13.1/loading.gif +0 -0
  85. data/coverage/assets/0.13.1/magnify.png +0 -0
  86. data/coverage/index.html +0 -15014
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e9ea6677f60dadfb539ccb221a11e2b849c3952c9fe16e0a1a2ea1efa21d78a5
4
- data.tar.gz: 87cd0d2879550d892a2da118e2748ce793327cf7692954c5844ab5d3d9699555
3
+ metadata.gz: 54db300e7891f1cf05b6f0cee2ad9ed00694a7057e8e4cdbd8cdf73ebe430da6
4
+ data.tar.gz: 5cbf0243b4032cd7feb1624a56c192e7439574c46ea6932df8ddcf5b3e1ccf18
5
5
  SHA512:
6
- metadata.gz: e0e4d45deef7d00ec921c5f10a3b96c876ea79347a14d27b202acbcd954b50e5bef5f82afa4597fba3d79ccedb912d90d7403d014b742d313e0abcfac4ef1e37
7
- data.tar.gz: 0b0fd601a082a23f951ba7616336b12e0ddfe6f970bdb5897c21c5c36fa08853e2afa7d09e9698dba3e621702db9784f915a8dfe0e85a6f2c408f17ee698146a
6
+ metadata.gz: 9823f6b88d45a45a9ed566a307aa5dd4b10c8299c7952b906ec96c17489128361566ebfec4e97fe577588408d6ac9aa5cab35aa99630351d53c51a8e2b5919f6
7
+ data.tar.gz: cd91f12a7ce839f698be56f7d740d3f1a02d6b92ea3f2ce9fc3f5dff06955a6f33d412b1604afd5d6ce51e9f1fb34d5af9159bf9db02c866d1bdaa3acd7f6893
@@ -0,0 +1,24 @@
1
+ ---
2
+ name: coverage
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+ pull_request:
8
+ jobs:
9
+ coverage:
10
+ runs-on: ubuntu-latest
11
+ steps:
12
+ - uses: actions/checkout@v4
13
+ - uses: ruby/setup-ruby@v1
14
+ with:
15
+ ruby-version: 3.4
16
+ bundler-cache: true
17
+ - name: Run tests with coverage
18
+ run: bundle exec rake spec
19
+ - name: Upload coverage to Codecov
20
+ uses: codecov/codecov-action@v5
21
+ with:
22
+ files: coverage/.resultset.json
23
+ fail_ci_if_error: true
24
+ token: ${{ secrets.CODECOV_TOKEN }}
@@ -0,0 +1,17 @@
1
+ name: Danger Comment
2
+
3
+ on:
4
+ workflow_run:
5
+ workflows: [Danger]
6
+ types: [completed]
7
+
8
+ permissions:
9
+ actions: read
10
+ issues: write
11
+ pull-requests: write
12
+ contents: read
13
+
14
+ jobs:
15
+ comment:
16
+ uses: numbata/danger-pr-comment/.github/workflows/danger-comment.yml@v0.1.0
17
+ secrets: inherit
@@ -0,0 +1,12 @@
1
+ ---
2
+ name: Danger
3
+ on:
4
+ pull_request:
5
+ types: [opened, reopened, edited, synchronize]
6
+ jobs:
7
+ danger:
8
+ uses: numbata/danger-pr-comment/.github/workflows/danger-run.yml@v0.1.0
9
+ secrets: inherit
10
+ with:
11
+ ruby-version: "3.3"
12
+ danger-args: "dry_run --base=origin/main"
@@ -0,0 +1,20 @@
1
+ name: Lint
2
+ on:
3
+ push:
4
+ branches:
5
+ - main
6
+ pull_request:
7
+ jobs:
8
+ rubocop:
9
+ name: RuboCop
10
+ runs-on: ubuntu-latest
11
+ steps:
12
+ - name: Checkout
13
+ uses: actions/checkout@v3
14
+ - name: Set up Ruby
15
+ uses: ruby/setup-ruby@v1
16
+ with:
17
+ ruby-version: 3.3
18
+ bundler-cache: true
19
+ - run: bundle exec rubocop
20
+
@@ -0,0 +1,14 @@
1
+ name: Release
2
+
3
+ on:
4
+ workflow_dispatch:
5
+
6
+ permissions:
7
+ contents: write
8
+ id-token: write
9
+
10
+ jobs:
11
+ release:
12
+ uses: dblock/ruby-gem-release/.github/workflows/release.yml@v0.3.1
13
+ with:
14
+ ruby-version: '3.3'
@@ -0,0 +1,25 @@
1
+ ---
2
+ name: test
3
+ on:
4
+ push:
5
+ branches:
6
+ - main
7
+ pull_request:
8
+ jobs:
9
+ test:
10
+ runs-on: ubuntu-latest
11
+ strategy:
12
+ fail-fast: false
13
+ matrix:
14
+ entry:
15
+ - { ruby: '3.3' }
16
+ - { ruby: '3.4' }
17
+ - { ruby: '4.0' }
18
+ name: test (${{ matrix.entry.ruby }})
19
+ steps:
20
+ - uses: actions/checkout@v3
21
+ - uses: ruby/setup-ruby@v1
22
+ with:
23
+ ruby-version: ${{ matrix.entry.ruby }}
24
+ - run: bundle install --jobs=3 --retry=3
25
+ - run: bundle exec rake spec
data/.gitignore ADDED
@@ -0,0 +1,6 @@
1
+ Gemfile.lock
2
+ pkg
3
+ coverage
4
+ .DS_Store
5
+ .bundle/
6
+ vendor/bundle/
data/.rspec ADDED
@@ -0,0 +1,2 @@
1
+ --format documentation
2
+ --color
data/.rubocop.yml ADDED
@@ -0,0 +1,26 @@
1
+ AllCops:
2
+ TargetRubyVersion: 3.3
3
+ NewCops: enable
4
+ Exclude:
5
+ - vendor/**/*
6
+
7
+ Style/HashEachMethods:
8
+ Enabled: true
9
+
10
+ Style/HashTransformKeys:
11
+ Enabled: true
12
+
13
+ Style/HashTransformValues:
14
+ Enabled: true
15
+
16
+ Metrics:
17
+ Enabled: false
18
+
19
+ Layout/EndOfLine:
20
+ EnforcedStyle: lf
21
+
22
+ plugins:
23
+ - rubocop-rake
24
+ - rubocop-rspec
25
+
26
+ inherit_from: .rubocop_todo.yml
data/.rubocop_todo.yml ADDED
@@ -0,0 +1,332 @@
1
+ # This configuration was generated by
2
+ # `rubocop --auto-gen-config`
3
+ # on 2026-08-18 00:50:15 UTC using RuboCop version 1.84.0.
4
+ # The point is for the user to remove these configuration records
5
+ # one by one as the offenses are removed from the code base.
6
+ # Note that changes in the inspected code, or installation of new
7
+ # versions of RuboCop, may require this file to be generated again.
8
+
9
+ # Offense count: 2
10
+ # Configuration parameters: EnforcedStyle, AllowedGems.
11
+ # SupportedStyles: Gemfile, gems.rb, gemspec
12
+ Gemspec/DevelopmentDependencies:
13
+ Exclude:
14
+ - 'ruby-link-checker.gemspec'
15
+
16
+ # Offense count: 1
17
+ # This cop supports safe autocorrection (--autocorrect).
18
+ # Configuration parameters: EnforcedStyleAlignWith.
19
+ # SupportedStylesAlignWith: either, start_of_block, start_of_line
20
+ Layout/BlockAlignment:
21
+ Exclude:
22
+ - 'spec/ruby-link-checker/checker_spec.rb'
23
+
24
+ # Offense count: 1
25
+ # This cop supports safe autocorrection (--autocorrect).
26
+ Layout/EmptyLineAfterGuardClause:
27
+ Exclude:
28
+ - 'lib/ruby-link-checker/checker.rb'
29
+
30
+ # Offense count: 3
31
+ # This cop supports safe autocorrection (--autocorrect).
32
+ Layout/EmptyLineAfterMagicComment:
33
+ Exclude:
34
+ - 'lib/ruby-link-checker/logger.rb'
35
+ - 'spec/ruby-link-checker/checker_spec.rb'
36
+ - 'spec/ruby-link-checker/config_spec.rb'
37
+
38
+ # Offense count: 3
39
+ # This cop supports safe autocorrection (--autocorrect).
40
+ # Configuration parameters: Width, EnforcedStyleAlignWith, AllowedPatterns.
41
+ # SupportedStylesAlignWith: start_of_line, relative_to_receiver
42
+ Layout/IndentationWidth:
43
+ Exclude:
44
+ - 'spec/ruby-link-checker/checker_spec.rb'
45
+ - 'spec/ruby-link-checker/config_spec.rb'
46
+
47
+ # Offense count: 4
48
+ # This cop supports safe autocorrection (--autocorrect).
49
+ # Configuration parameters: EnforcedStyle.
50
+ # SupportedStyles: final_newline, final_blank_line
51
+ Layout/TrailingEmptyLines:
52
+ Exclude:
53
+ - 'lib/ruby-link-checker/logger.rb'
54
+ - 'spec/ruby-link-checker/checker_spec.rb'
55
+ - 'spec/ruby-link-checker/config_spec.rb'
56
+ - 'spec/spec_helper.rb'
57
+
58
+ # Offense count: 1
59
+ # This cop supports safe autocorrection (--autocorrect).
60
+ # Configuration parameters: AllowInHeredoc.
61
+ Layout/TrailingWhitespace:
62
+ Exclude:
63
+ - 'spec/ruby-link-checker/config_spec.rb'
64
+
65
+ # Offense count: 2
66
+ # Configuration parameters: AllowedMethods.
67
+ # AllowedMethods: enums
68
+ Lint/ConstantDefinitionInBlock:
69
+ Exclude:
70
+ - 'spec/ruby-link-checker/async/http/checker_spec.rb'
71
+ - 'spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb'
72
+
73
+ # Offense count: 1
74
+ # Configuration parameters: ExpectMatchingDefinition, CheckDefinitionPathHierarchy, CheckDefinitionPathHierarchyRoots, Regex, IgnoreExecutableScripts, AllowedAcronyms.
75
+ # CheckDefinitionPathHierarchyRoots: lib, spec, test, src
76
+ # AllowedAcronyms: CLI, DSL, ACL, API, ASCII, CPU, CSS, DNS, EOF, GUID, HTML, HTTP, HTTPS, ID, IP, JSON, LHS, QPS, RAM, RHS, RPC, SLA, SMTP, SQL, SSH, TCP, TLS, TTL, UDP, UI, UID, UUID, URI, URL, UTF8, VM, XML, XMPP, XSRF, XSS
77
+ Naming/FileName:
78
+ Exclude:
79
+ - 'Rakefile.rb'
80
+ - 'lib/ruby-link-checker.rb'
81
+
82
+ # Offense count: 1
83
+ # Configuration parameters: MinNameLength, AllowNamesEndingInNumbers, AllowedNames, ForbiddenNames.
84
+ # AllowedNames: as, at, by, cc, db, id, if, in, io, ip, of, on, os, pp, to
85
+ Naming/MethodParameterName:
86
+ Exclude:
87
+ - 'lib/ruby-link-checker/callbacks.rb'
88
+
89
+ # Offense count: 3
90
+ RSpec/AnyInstance:
91
+ Exclude:
92
+ - 'spec/ruby-link-checker/net/http/checker_spec.rb'
93
+ - 'spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb'
94
+
95
+ # Offense count: 1
96
+ # This cop supports safe autocorrection (--autocorrect).
97
+ # Configuration parameters: EnforcedStyle.
98
+ # SupportedStyles: be, be_nil
99
+ RSpec/BeNil:
100
+ Exclude:
101
+ - 'spec/ruby-link-checker/config_spec.rb'
102
+
103
+ # Offense count: 3
104
+ RSpec/BeforeAfterAll:
105
+ Exclude:
106
+ - '**/spec/spec_helper.rb'
107
+ - '**/spec/rails_helper.rb'
108
+ - '**/spec/support/**/*.rb'
109
+ - 'spec/ruby-link-checker/async/http/checker_spec.rb'
110
+ - 'spec/ruby-link-checker/net/http/checker_spec.rb'
111
+ - 'spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb'
112
+
113
+ # Offense count: 36
114
+ # Configuration parameters: Prefixes, AllowedPatterns.
115
+ # Prefixes: when, with, without
116
+ RSpec/ContextWording:
117
+ Exclude:
118
+ - 'spec/ruby-link-checker/async/http/checker_spec.rb'
119
+ - 'spec/ruby-link-checker/callbacks_spec.rb'
120
+ - 'spec/ruby-link-checker/checker_spec.rb'
121
+ - 'spec/ruby-link-checker/config_spec.rb'
122
+ - 'spec/ruby-link-checker/net/http/checker_spec.rb'
123
+ - 'spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb'
124
+ - 'spec/support/link_checker.rb'
125
+
126
+ # Offense count: 1
127
+ # This cop supports unsafe autocorrection (--autocorrect-all).
128
+ # Configuration parameters: SkipBlocks, EnforcedStyle, OnlyStaticConstants.
129
+ # SupportedStyles: described_class, explicit
130
+ RSpec/DescribedClass:
131
+ Exclude:
132
+ - 'spec/ruby-link-checker/checker_spec.rb'
133
+
134
+ # Offense count: 3
135
+ # This cop supports safe autocorrection (--autocorrect).
136
+ # Configuration parameters: AllowConsecutiveOneLiners.
137
+ RSpec/EmptyLineAfterExample:
138
+ Exclude:
139
+ - 'spec/ruby-link-checker/config_spec.rb'
140
+
141
+ # Offense count: 14
142
+ # Configuration parameters: CountAsOne.
143
+ RSpec/ExampleLength:
144
+ Max: 9
145
+
146
+ # Offense count: 4
147
+ RSpec/ExpectInHook:
148
+ Exclude:
149
+ - 'spec/ruby-link-checker/async/http/checker_spec.rb'
150
+ - 'spec/ruby-link-checker/net/http/checker_spec.rb'
151
+ - 'spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb'
152
+
153
+ # Offense count: 6
154
+ # Configuration parameters: AssignmentOnly.
155
+ RSpec/InstanceVariable:
156
+ Exclude:
157
+ - 'spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb'
158
+ - 'spec/support/link_checker.rb'
159
+ - 'spec/support/with_result.rb'
160
+
161
+ # Offense count: 6
162
+ RSpec/LeakyConstantDeclaration:
163
+ Exclude:
164
+ - 'spec/ruby-link-checker/async/http/checker_spec.rb'
165
+ - 'spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb'
166
+
167
+ # Offense count: 2
168
+ # Configuration parameters: EnforcedStyle.
169
+ # SupportedStyles: have_received, receive
170
+ RSpec/MessageSpies:
171
+ Exclude:
172
+ - 'spec/ruby-link-checker/async/http/checker_spec.rb'
173
+ - 'spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb'
174
+
175
+ # Offense count: 23
176
+ RSpec/MultipleExpectations:
177
+ Max: 9
178
+
179
+ # Offense count: 58
180
+ # Configuration parameters: EnforcedStyle, IgnoreSharedExamples.
181
+ # SupportedStyles: always, named_only
182
+ RSpec/NamedSubject:
183
+ Exclude:
184
+ - 'spec/ruby-link-checker/callbacks_spec.rb'
185
+ - 'spec/support/link_checker.rb'
186
+ - 'spec/support/with_result.rb'
187
+ - 'spec/support/with_url.rb'
188
+
189
+ # Offense count: 26
190
+ # Configuration parameters: AllowedGroups.
191
+ RSpec/NestedGroups:
192
+ Max: 6
193
+
194
+ # Offense count: 8
195
+ # Configuration parameters: CustomTransform, IgnoreMethods, IgnoreMetadata, InflectorPath, EnforcedInflector.
196
+ # SupportedInflectors: default, active_support
197
+ RSpec/SpecFilePathFormat:
198
+ Exclude:
199
+ - '**/spec/routing/**/*'
200
+ - 'spec/ruby-link-checker/async/http/checker_spec.rb'
201
+ - 'spec/ruby-link-checker/callbacks_spec.rb'
202
+ - 'spec/ruby-link-checker/checker_spec.rb'
203
+ - 'spec/ruby-link-checker/config_spec.rb'
204
+ - 'spec/ruby-link-checker/errors/redirect_loop_error_spec.rb'
205
+ - 'spec/ruby-link-checker/net/http/checker_spec.rb'
206
+ - 'spec/ruby-link-checker/result_error_spec.rb'
207
+ - 'spec/ruby-link-checker/result_spec.rb'
208
+ - 'spec/ruby-link-checker/task_spec.rb'
209
+ - 'spec/ruby-link-checker/tasks_spec.rb'
210
+ - 'spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb'
211
+ - 'spec/ruby-link-checker/version_spec.rb'
212
+
213
+ # Offense count: 39
214
+ RSpec/SubjectStub:
215
+ Exclude:
216
+ - 'spec/ruby-link-checker/callbacks_spec.rb'
217
+ - 'spec/support/link_checker.rb'
218
+ - 'spec/support/with_result.rb'
219
+
220
+ # Offense count: 2
221
+ # This cop supports safe autocorrection (--autocorrect).
222
+ # Configuration parameters: AllowOnConstant, AllowOnSelfClass.
223
+ Style/CaseEquality:
224
+ Exclude:
225
+ - 'spec/support/link_checker.rb'
226
+
227
+ # Offense count: 3
228
+ # This cop supports unsafe autocorrection (--autocorrect-all).
229
+ Style/ComparableBetween:
230
+ Exclude:
231
+ - 'lib/ruby-link-checker/async/http/result.rb'
232
+ - 'lib/ruby-link-checker/net/http/result.rb'
233
+ - 'lib/ruby-link-checker/typhoeus/hydra/result.rb'
234
+
235
+ # Offense count: 25
236
+ # Configuration parameters: AllowedConstants.
237
+ Style/Documentation:
238
+ Enabled: false
239
+
240
+ # Offense count: 1
241
+ # This cop supports safe autocorrection (--autocorrect).
242
+ # Configuration parameters: EnforcedStyle.
243
+ # SupportedStyles: trailing_conditional, ternary
244
+ Style/EmptyStringInsideInterpolation:
245
+ Exclude:
246
+ - 'lib/ruby-link-checker/result.rb'
247
+
248
+ # Offense count: 18
249
+ # This cop supports unsafe autocorrection (--autocorrect-all).
250
+ # Configuration parameters: EnforcedStyle.
251
+ # SupportedStyles: always, always_true, never
252
+ Style/FrozenStringLiteralComment:
253
+ Enabled: false
254
+
255
+ # Offense count: 1
256
+ # This cop supports unsafe autocorrection (--autocorrect-all).
257
+ Style/GlobalStdStream:
258
+ Exclude:
259
+ - 'lib/ruby-link-checker/logger.rb'
260
+
261
+ # Offense count: 1
262
+ Style/MissingRespondToMissing:
263
+ Exclude:
264
+ - 'lib/ruby-link-checker/callbacks.rb'
265
+
266
+ # Offense count: 4
267
+ # This cop supports unsafe autocorrection (--autocorrect-all).
268
+ # Configuration parameters: EnforcedStyle, Autocorrect.
269
+ # SupportedStyles: module_function, extend_self, forbidden
270
+ Style/ModuleFunction:
271
+ Exclude:
272
+ - 'lib/ruby-link-checker/async/http/config.rb'
273
+ - 'lib/ruby-link-checker/config.rb'
274
+ - 'lib/ruby-link-checker/net/http/config.rb'
275
+ - 'lib/ruby-link-checker/typhoeus/hydra/config.rb'
276
+
277
+ # Offense count: 2
278
+ # This cop supports unsafe autocorrection (--autocorrect-all).
279
+ # Configuration parameters: EnforcedStyle, AllowedMethods, AllowedPatterns.
280
+ # SupportedStyles: predicate, comparison
281
+ Style/NumericPredicate:
282
+ Exclude:
283
+ - 'spec/**/*'
284
+ - 'lib/ruby-link-checker/tasks.rb'
285
+
286
+ # Offense count: 1
287
+ # This cop supports safe autocorrection (--autocorrect).
288
+ Style/RescueModifier:
289
+ Exclude:
290
+ - 'lib/ruby-link-checker/tasks.rb'
291
+
292
+ # Offense count: 1
293
+ # This cop supports unsafe autocorrection (--autocorrect-all).
294
+ # Configuration parameters: Mode.
295
+ Style/StringConcatenation:
296
+ Exclude:
297
+ - 'lib/ruby-link-checker/result.rb'
298
+
299
+ # Offense count: 2
300
+ # This cop supports safe autocorrection (--autocorrect).
301
+ # Configuration parameters: EnforcedStyle, ConsistentQuotesInMultiline.
302
+ # SupportedStyles: single_quotes, double_quotes
303
+ Style/StringLiterals:
304
+ Exclude:
305
+ - 'lib/ruby-link-checker/checker.rb'
306
+
307
+ # Offense count: 3
308
+ # This cop supports safe autocorrection (--autocorrect).
309
+ Style/SuperArguments:
310
+ Exclude:
311
+ - 'lib/ruby-link-checker/net/http/checker.rb'
312
+ - 'lib/ruby-link-checker/typhoeus/hydra/checker.rb'
313
+ - 'spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb'
314
+
315
+ # Offense count: 7
316
+ # This cop supports safe autocorrection (--autocorrect).
317
+ Style/SuperWithArgsParentheses:
318
+ Exclude:
319
+ - 'lib/ruby-link-checker/errors/redirect_loop_error.rb'
320
+ - 'lib/ruby-link-checker/net/http/checker.rb'
321
+ - 'lib/ruby-link-checker/net/http/result.rb'
322
+ - 'lib/ruby-link-checker/result.rb'
323
+ - 'lib/ruby-link-checker/typhoeus/hydra/checker.rb'
324
+ - 'lib/ruby-link-checker/typhoeus/hydra/result.rb'
325
+ - 'spec/ruby-link-checker/typhoeus/hydra/checker_spec.rb'
326
+
327
+ # Offense count: 1
328
+ # This cop supports safe autocorrection (--autocorrect).
329
+ # Configuration parameters: AllowHeredoc, AllowURI, AllowQualifiedName, URISchemes, AllowRBSInlineAnnotation, AllowCopDirectives, AllowedPatterns, SplitStrings.
330
+ # URISchemes: http, https
331
+ Layout/LineLength:
332
+ Max: 123
data/AGENTS.md ADDED
@@ -0,0 +1,23 @@
1
+ # Contributor instructions
2
+
3
+ Keep changes focused and preserve existing behavior unless a change is explicitly requested. Follow CONTRIBUTING.md and document public behavior in README.md.
4
+
5
+ ## Changelog and pull requests
6
+
7
+ Add entries under the current `(Next)` heading in CHANGELOG.md and retain `Your contribution here`. Include the implementation PR number, its URL, and contributor attribution using this format:
8
+
9
+ ```markdown
10
+ * [#123](https://github.com/dblock/ruby-link-checker/pull/123): Describe the change - [@contributor](https://github.com/contributor).
11
+ ```
12
+
13
+ Predict the PR number before opening a new PR, then verify the assigned number and correct the entry if necessary. Issue references may supplement but do not replace the implementation PR link.
14
+
15
+ Keep Markdown paragraphs on one line. Keep each PR branch to one commit, squash follow-up changes before pushing, and use `--force-with-lease` when updating rewritten PR history. Never force-push the default branch.
16
+
17
+ ## Validation
18
+
19
+ Run focused RSpec tests for behavior changes and `bundle exec rubocop` before committing. `bundle exec rake` runs both the full specs and RuboCop. Avoid repeated intermediate test runs; rerun when failures or subsequent changes require it.
20
+
21
+ For changelog or README changes, run `bundle exec danger dry_run --base=origin/main`; Danger checks changelog entries and README table-of-contents consistency. Keep the temporary `git < 6` dependency pin until Danger supports git 6; the Gemfile comment links the upstream fix.
22
+
23
+ Do not commit Gemfile.lock; this repository ignores it. Include `Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>` in AI-assisted commits and disclose AI involvement when posting GitHub comments on behalf of the user.
data/CHANGELOG.md CHANGED
@@ -1,3 +1,30 @@
1
+ ### 0.5.1 (2026/11/08)
2
+
3
+ * [#30](https://github.com/dblock/ruby-link-checker/pull/30): Updated ruby-gem-release to 0.3.1 - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
4
+ * [#29](https://github.com/dblock/ruby-link-checker/pull/29): Removed accidentally tracked Bundler artifacts, ignored local Bundler configuration and installed gems, and restricted gem packaging to tracked files - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
5
+ * [#28](https://github.com/dblock/ruby-link-checker/pull/28): Updated ruby-gem-release to 0.3.0 and removed the unsupported dry-run release input and instructions - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
6
+
7
+ ### 0.5.0 (2026/11/07)
8
+
9
+ * [#27](https://github.com/dblock/ruby-link-checker/pull/27): Avoided duplicate test and lint runs by checking pull requests and pushes to `main` only - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
10
+ * [#26](https://github.com/dblock/ruby-link-checker/pull/26): Added ruby-gem-release automation with manual, dry-run-first releases and RubyGems Trusted Publishing - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
11
+ * [#23](https://github.com/dblock/ruby-link-checker/pull/23): Fixed chained relative redirects, bounded redirect following with `max_redirects`, enabled plain HTTP in the Net::HTTP checker, and corrected retry documentation - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
12
+ * [#24](https://github.com/dblock/ruby-link-checker/pull/24): Added transient-only retries, opt-in retry delays/backoff/jitter and `Retry-After` handling, transport error categories, and an Async concurrency limit - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
13
+ * [#25](https://github.com/dblock/ruby-link-checker/pull/25): Added opt-in URL deduplication and atomic TTL-based success caching, preserving per-submission metadata and query values - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
14
+ * [#8](https://github.com/dblock/ruby-link-checker/issues/8): Added `protocol` configuration option to `LinkChecker::Async::HTTP` to force HTTP/1 or HTTP/2 - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
15
+
16
+ ### 0.4.0 (2026/8/17)
17
+
18
+ * [#13](https://github.com/dblock/ruby-link-checker/pull/13): Fix `SystemStackError` caused by infinite recursion in `_handle_result` - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
19
+ * [#14](https://github.com/dblock/ruby-link-checker/pull/14): Migrate Danger to use danger-pr-comment workflow - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
20
+ * [#14](https://github.com/dblock/ruby-link-checker/pull/14): Removed Code Climate - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
21
+ * [#15](https://github.com/dblock/ruby-link-checker/pull/15): Added Codecov - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
22
+ * [#18](https://github.com/dblock/ruby-link-checker/pull/18): Added Ruby 4.0 to the CI test matrix - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
23
+ * [#19](https://github.com/dblock/ruby-link-checker/pull/19): Added `LinkChecker::Async::HTTP`, a link checker based on [async-http](https://github.com/socketry/async-http) - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
24
+ * [#19](https://github.com/dblock/ruby-link-checker/pull/19): Dropped support for Ruby < 3.3 - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
25
+ * [#20](https://github.com/dblock/ruby-link-checker/pull/20): Added support for custom headers - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
26
+ * [#21](https://github.com/dblock/ruby-link-checker/pull/21): Improved test coverage to 100% and fixed Danger dry_run failure by unpinning `danger-changelog` - [@dblock](https://github.com/dblock), [@Copilot](https://github.com/Copilot).
27
+
1
28
  ### 0.3.0 (2025-07-05)
2
29
 
3
30
  * [#10](https://github.com/dblock/ruby-link-checker/pull/10): Add a space after `:` to help rendering in GHA - [@dblock](https://github.com/dblock).
data/CONTRIBUTING.md CHANGED
@@ -120,6 +120,10 @@ Go back to your pull request after a few minutes and see whether it passed muste
120
120
 
121
121
  It's likely that your change will not be merged and that the nitpicky maintainers will ask you to do more, or fix seemingly benign problems. Hang on there!
122
122
 
123
+ ## Releases
124
+
125
+ See [RELEASING.md](RELEASING.md) for the manual release workflow and one-time Trusted Publishing setup.
126
+
123
127
  ## Thank You
124
128
 
125
129
  Please do know that we really appreciate and value your time and work. We love you, really.
data/Dangerfile CHANGED
@@ -1,4 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ danger.import_dangerfile(gem: 'danger-pr-comment')
4
+
3
5
  changelog.check!
4
6
  toc.check!
data/Gemfile CHANGED
@@ -8,12 +8,16 @@ gem 'rake'
8
8
 
9
9
  group :development, :test do
10
10
  gem 'danger'
11
- gem 'danger-changelog', '0.6.1'
11
+ gem 'danger-changelog', '0.8.0'
12
+ gem 'danger-pr-comment'
12
13
  gem 'danger-toc', '0.2.0'
14
+ # Temporary until Danger's git 6 support lands: https://github.com/danger/danger/pull/1561
15
+ gem 'git', '< 6', require: false
13
16
  gem 'rspec', '~> 3.0'
14
17
  gem 'rubocop', '~> 1.0'
15
18
  gem 'rubocop-rake'
16
19
  gem 'rubocop-rspec'
20
+ gem 'ruby-gem-release', '~> 0.3.1', require: false
17
21
  gem 'vcr'
18
22
  gem 'webmock'
19
23
  end