packageurl-ruby 0.1.0 → 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 +4 -4
- data/.github/workflows/ci.yml +1 -4
- data/.rubocop.yml +4 -2
- data/.ruby-version +1 -1
- data/Gemfile +4 -4
- data/Gemfile.lock +130 -66
- data/LICENSE +21 -0
- data/README.md +1 -1
- data/Rakefile +5 -1
- data/lib/package_url/version.rb +1 -1
- data/lib/package_url.rb +35 -8
- data/packageurl-ruby.gemspec +2 -1
- data/sig/package_url.rbs +24 -25
- metadata +7 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 30f2ee2e31fb703a97ae074c916d1c3f32cf0f449dad38afc147ed3cdf103af0
|
4
|
+
data.tar.gz: 7f691b801b89e59aaba6dee9ada77a077e8112d6d64618dd936db4f73d318ae2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ae26ee3f3dedeae6c7369ea2118c1170d3624273b76d12bbb9226bd3c3e68eeeb73a3da9b44e89b3d47af06f10bbe75657a6c9515ccead63ac286c9a58e5735c
|
7
|
+
data.tar.gz: e893c33c957214ebf090e12a527b847c09fc6b6801dedceb9004a6174e3cc35e7146234dc8b6a9cde9ac6171bdc66442d42f70cf4fd1c1dde9f4ed0c062b97bd
|
data/.github/workflows/ci.yml
CHANGED
data/.rubocop.yml
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
AllCops:
|
2
|
-
TargetRubyVersion: 2
|
2
|
+
TargetRubyVersion: 3.2
|
3
3
|
NewCops: enable
|
4
|
+
SuggestExtensions: false
|
4
5
|
Metrics/AbcSize:
|
5
6
|
Enabled: false
|
6
7
|
Metrics/BlockLength:
|
@@ -8,6 +9,7 @@ Metrics/BlockLength:
|
|
8
9
|
- "Rakefile"
|
9
10
|
- "**/*.rake"
|
10
11
|
- "spec/**/*.rb"
|
12
|
+
- "*.gemspec"
|
11
13
|
Metrics/CyclomaticComplexity:
|
12
14
|
Enabled: false
|
13
15
|
Metrics/ClassLength:
|
@@ -17,6 +19,6 @@ Metrics/MethodLength:
|
|
17
19
|
Metrics/ParameterLists:
|
18
20
|
Max: 7
|
19
21
|
Metrics/PerceivedComplexity:
|
20
|
-
Max:
|
22
|
+
Max: 30
|
21
23
|
Style/ConditionalAssignment:
|
22
24
|
Enabled: false
|
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
3.
|
1
|
+
3.4.2
|
data/Gemfile
CHANGED
@@ -7,8 +7,8 @@ gemspec
|
|
7
7
|
gem 'bundler', '~> 2.0'
|
8
8
|
gem 'rake', '~> 13.0'
|
9
9
|
gem 'rspec', '~> 3.0'
|
10
|
-
gem 'rubocop', '~> 1.
|
11
|
-
gem 'rubocop-rake', '~> 0.
|
12
|
-
gem 'rubocop-rspec', '~> 2.
|
13
|
-
gem 'steep', '~>
|
10
|
+
gem 'rubocop', '~> 1.74'
|
11
|
+
gem 'rubocop-rake', '~> 0.7'
|
12
|
+
gem 'rubocop-rspec', '~> 2.19'
|
13
|
+
gem 'steep', '~> 1.10.0'
|
14
14
|
gem 'yard', '~> 0.9.0'
|
data/Gemfile.lock
CHANGED
@@ -1,100 +1,164 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
packageurl-ruby (0.
|
4
|
+
packageurl-ruby (0.2.0)
|
5
5
|
|
6
6
|
GEM
|
7
7
|
remote: https://rubygems.org/
|
8
8
|
specs:
|
9
|
-
activesupport (
|
10
|
-
|
9
|
+
activesupport (8.0.2)
|
10
|
+
base64
|
11
|
+
benchmark (>= 0.3)
|
12
|
+
bigdecimal
|
13
|
+
concurrent-ruby (~> 1.0, >= 1.3.1)
|
14
|
+
connection_pool (>= 2.2.5)
|
15
|
+
drb
|
11
16
|
i18n (>= 1.6, < 2)
|
17
|
+
logger (>= 1.4.2)
|
12
18
|
minitest (>= 5.1)
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
19
|
+
securerandom (>= 0.3)
|
20
|
+
tzinfo (~> 2.0, >= 2.0.5)
|
21
|
+
uri (>= 0.13.1)
|
22
|
+
ast (2.4.3)
|
23
|
+
base64 (0.2.0)
|
24
|
+
benchmark (0.4.0)
|
25
|
+
bigdecimal (3.1.9)
|
26
|
+
concurrent-ruby (1.3.5)
|
27
|
+
connection_pool (2.5.0)
|
28
|
+
csv (3.3.3)
|
29
|
+
diff-lcs (1.6.0)
|
30
|
+
drb (2.2.1)
|
31
|
+
ffi (1.17.1)
|
32
|
+
ffi (1.17.1-aarch64-linux-gnu)
|
33
|
+
ffi (1.17.1-aarch64-linux-musl)
|
34
|
+
ffi (1.17.1-arm-linux-gnu)
|
35
|
+
ffi (1.17.1-arm-linux-musl)
|
36
|
+
ffi (1.17.1-arm64-darwin)
|
37
|
+
ffi (1.17.1-x86-linux-gnu)
|
38
|
+
ffi (1.17.1-x86-linux-musl)
|
39
|
+
ffi (1.17.1-x86_64-darwin)
|
40
|
+
ffi (1.17.1-x86_64-linux-gnu)
|
41
|
+
ffi (1.17.1-x86_64-linux-musl)
|
42
|
+
fileutils (1.7.3)
|
43
|
+
i18n (1.14.7)
|
20
44
|
concurrent-ruby (~> 1.0)
|
21
|
-
|
22
|
-
|
45
|
+
json (2.10.2)
|
46
|
+
language_server-protocol (3.17.0.4)
|
47
|
+
lint_roller (1.1.0)
|
48
|
+
listen (3.9.0)
|
23
49
|
rb-fsevent (~> 0.10, >= 0.10.3)
|
24
50
|
rb-inotify (~> 0.9, >= 0.9.10)
|
25
|
-
|
26
|
-
|
27
|
-
|
51
|
+
logger (1.6.6)
|
52
|
+
minitest (5.25.5)
|
53
|
+
mutex_m (0.3.0)
|
54
|
+
parallel (1.26.3)
|
55
|
+
parser (3.3.7.2)
|
28
56
|
ast (~> 2.4.1)
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
57
|
+
racc
|
58
|
+
racc (1.8.1)
|
59
|
+
rainbow (3.1.1)
|
60
|
+
rake (13.2.1)
|
61
|
+
rb-fsevent (0.11.2)
|
62
|
+
rb-inotify (0.11.1)
|
33
63
|
ffi (~> 1.0)
|
34
|
-
rbs (
|
35
|
-
|
36
|
-
|
37
|
-
rspec (3.
|
38
|
-
rspec-core (~> 3.
|
39
|
-
rspec-expectations (~> 3.
|
40
|
-
rspec-mocks (~> 3.
|
41
|
-
rspec-core (3.
|
42
|
-
rspec-support (~> 3.
|
43
|
-
rspec-expectations (3.
|
64
|
+
rbs (3.9.0)
|
65
|
+
logger
|
66
|
+
regexp_parser (2.10.0)
|
67
|
+
rspec (3.13.0)
|
68
|
+
rspec-core (~> 3.13.0)
|
69
|
+
rspec-expectations (~> 3.13.0)
|
70
|
+
rspec-mocks (~> 3.13.0)
|
71
|
+
rspec-core (3.13.3)
|
72
|
+
rspec-support (~> 3.13.0)
|
73
|
+
rspec-expectations (3.13.3)
|
44
74
|
diff-lcs (>= 1.2.0, < 2.0)
|
45
|
-
rspec-support (~> 3.
|
46
|
-
rspec-mocks (3.
|
75
|
+
rspec-support (~> 3.13.0)
|
76
|
+
rspec-mocks (3.13.2)
|
47
77
|
diff-lcs (>= 1.2.0, < 2.0)
|
48
|
-
rspec-support (~> 3.
|
49
|
-
rspec-support (3.
|
50
|
-
rubocop (1.
|
78
|
+
rspec-support (~> 3.13.0)
|
79
|
+
rspec-support (3.13.2)
|
80
|
+
rubocop (1.74.0)
|
81
|
+
json (~> 2.3)
|
82
|
+
language_server-protocol (~> 3.17.0.2)
|
83
|
+
lint_roller (~> 1.1.0)
|
51
84
|
parallel (~> 1.10)
|
52
|
-
parser (>= 3.
|
85
|
+
parser (>= 3.3.0.2)
|
53
86
|
rainbow (>= 2.2.2, < 4.0)
|
54
|
-
regexp_parser (>=
|
55
|
-
|
56
|
-
rubocop-ast (>= 1.12.0, < 2.0)
|
87
|
+
regexp_parser (>= 2.9.3, < 3.0)
|
88
|
+
rubocop-ast (>= 1.38.0, < 2.0)
|
57
89
|
ruby-progressbar (~> 1.7)
|
58
|
-
unicode-display_width (>=
|
59
|
-
rubocop-ast (1.
|
60
|
-
parser (>= 3.
|
61
|
-
rubocop-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
90
|
+
unicode-display_width (>= 2.4.0, < 4.0)
|
91
|
+
rubocop-ast (1.41.0)
|
92
|
+
parser (>= 3.3.7.2)
|
93
|
+
rubocop-capybara (2.22.1)
|
94
|
+
lint_roller (~> 1.1)
|
95
|
+
rubocop (~> 1.72, >= 1.72.1)
|
96
|
+
rubocop-factory_bot (2.27.1)
|
97
|
+
lint_roller (~> 1.1)
|
98
|
+
rubocop (~> 1.72, >= 1.72.1)
|
99
|
+
rubocop-rake (0.7.1)
|
100
|
+
lint_roller (~> 1.1)
|
101
|
+
rubocop (>= 1.72.1)
|
102
|
+
rubocop-rspec (2.31.0)
|
103
|
+
rubocop (~> 1.40)
|
104
|
+
rubocop-capybara (~> 2.17)
|
105
|
+
rubocop-factory_bot (~> 2.22)
|
106
|
+
rubocop-rspec_rails (~> 2.28)
|
107
|
+
rubocop-rspec_rails (2.29.1)
|
108
|
+
rubocop (~> 1.61)
|
109
|
+
ruby-progressbar (1.13.0)
|
110
|
+
securerandom (0.4.1)
|
111
|
+
steep (1.10.0)
|
67
112
|
activesupport (>= 5.1)
|
68
|
-
|
113
|
+
concurrent-ruby (>= 1.1.10)
|
114
|
+
csv (>= 3.0.9)
|
115
|
+
fileutils (>= 1.1.0)
|
116
|
+
json (>= 2.1.0)
|
117
|
+
language_server-protocol (>= 3.17.0.4, < 4.0)
|
69
118
|
listen (~> 3.0)
|
70
|
-
|
71
|
-
|
119
|
+
logger (>= 1.3.0)
|
120
|
+
mutex_m (>= 0.3.0)
|
121
|
+
parser (>= 3.1)
|
72
122
|
rainbow (>= 2.2.2, < 4.0)
|
73
|
-
rbs (
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
123
|
+
rbs (~> 3.9)
|
124
|
+
securerandom (>= 0.1)
|
125
|
+
strscan (>= 1.0.0)
|
126
|
+
terminal-table (>= 2, < 5)
|
127
|
+
uri (>= 0.12.0)
|
128
|
+
strscan (3.1.2)
|
129
|
+
terminal-table (4.0.0)
|
130
|
+
unicode-display_width (>= 1.1.1, < 4)
|
131
|
+
tzinfo (2.0.6)
|
78
132
|
concurrent-ruby (~> 1.0)
|
79
|
-
unicode-display_width (
|
80
|
-
|
81
|
-
|
133
|
+
unicode-display_width (3.1.4)
|
134
|
+
unicode-emoji (~> 4.0, >= 4.0.4)
|
135
|
+
unicode-emoji (4.0.4)
|
136
|
+
uri (1.0.3)
|
137
|
+
yard (0.9.37)
|
82
138
|
|
83
139
|
PLATFORMS
|
84
|
-
|
85
|
-
|
86
|
-
|
140
|
+
aarch64-linux-gnu
|
141
|
+
aarch64-linux-musl
|
142
|
+
arm-linux-gnu
|
143
|
+
arm-linux-musl
|
144
|
+
arm64-darwin
|
145
|
+
ruby
|
146
|
+
x86-linux-gnu
|
147
|
+
x86-linux-musl
|
148
|
+
x86_64-darwin
|
149
|
+
x86_64-linux-gnu
|
150
|
+
x86_64-linux-musl
|
87
151
|
|
88
152
|
DEPENDENCIES
|
89
153
|
bundler (~> 2.0)
|
90
154
|
packageurl-ruby!
|
91
155
|
rake (~> 13.0)
|
92
156
|
rspec (~> 3.0)
|
93
|
-
rubocop (~> 1.
|
94
|
-
rubocop-rake (~> 0.
|
95
|
-
rubocop-rspec (~> 2.
|
96
|
-
steep (~>
|
157
|
+
rubocop (~> 1.74)
|
158
|
+
rubocop-rake (~> 0.7)
|
159
|
+
rubocop-rspec (~> 2.19)
|
160
|
+
steep (~> 1.10.0)
|
97
161
|
yard (~> 0.9.0)
|
98
162
|
|
99
163
|
BUNDLED WITH
|
100
|
-
2.
|
164
|
+
2.6.6
|
data/LICENSE
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
MIT License
|
2
|
+
|
3
|
+
Copyright (c) 2021 package-url
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
13
|
+
copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
21
|
+
SOFTWARE.
|
data/README.md
CHANGED
data/Rakefile
CHANGED
@@ -5,10 +5,14 @@ require 'rspec/core/rake_task'
|
|
5
5
|
|
6
6
|
RSpec::Core::RakeTask.new(:spec)
|
7
7
|
|
8
|
+
task :lint do
|
9
|
+
system 'rubocop'
|
10
|
+
end
|
11
|
+
|
8
12
|
namespace :steep do
|
9
13
|
task :check do
|
10
14
|
system 'steep check'
|
11
15
|
end
|
12
16
|
end
|
13
17
|
|
14
|
-
task default: %i[spec steep:check]
|
18
|
+
task default: %i[lint spec steep:check]
|
data/lib/package_url/version.rb
CHANGED
data/lib/package_url.rb
CHANGED
@@ -72,7 +72,14 @@ class PackageURL
|
|
72
72
|
# @raise [InvalidPackageURL] If the string is not a valid package URL.
|
73
73
|
# @return [PackageURL]
|
74
74
|
def self.parse(string)
|
75
|
-
components = {
|
75
|
+
components = {
|
76
|
+
type: nil,
|
77
|
+
namespace: nil,
|
78
|
+
name: nil,
|
79
|
+
version: nil,
|
80
|
+
qualifiers: nil,
|
81
|
+
subpath: nil
|
82
|
+
}
|
76
83
|
|
77
84
|
# Split the purl string once from right on '#'
|
78
85
|
# - The left side is the remainder
|
@@ -86,9 +93,14 @@ class PackageURL
|
|
86
93
|
# - This is the subpath
|
87
94
|
case string.rpartition('#')
|
88
95
|
in String => remainder, separator, String => subpath unless separator.empty?
|
89
|
-
|
90
|
-
|
91
|
-
|
96
|
+
subpath_components = []
|
97
|
+
subpath.split('/').each do |segment|
|
98
|
+
next if segment.empty? || segment == '.' || segment == '..'
|
99
|
+
|
100
|
+
subpath_components << URI.decode_www_form_component(segment)
|
101
|
+
end
|
102
|
+
|
103
|
+
components[:subpath] = subpath_components.compact.join('/')
|
92
104
|
|
93
105
|
string = remainder
|
94
106
|
else
|
@@ -145,10 +157,11 @@ class PackageURL
|
|
145
157
|
end
|
146
158
|
|
147
159
|
# Strip the remainder from leading and trailing '/'
|
160
|
+
# Use gsub to remove ALL leading slashes instead of just one
|
161
|
+
string = string.gsub(%r{^/+}, '').delete_suffix('/')
|
148
162
|
# - Split this once from left on '/'
|
149
163
|
# - The left side lowercased is the type
|
150
164
|
# - The right side is the remainder
|
151
|
-
string = string.delete_suffix('/')
|
152
165
|
case string.partition('/')
|
153
166
|
in String => type, separator, remainder unless separator.empty?
|
154
167
|
components[:type] = type
|
@@ -195,8 +208,16 @@ class PackageURL
|
|
195
208
|
components[:namespace] = nil
|
196
209
|
end
|
197
210
|
|
198
|
-
|
199
|
-
|
211
|
+
# Ensure type and name are not nil before creating the PackageURL instance
|
212
|
+
raise InvalidPackageURL, 'missing package type' if components[:type].nil?
|
213
|
+
raise InvalidPackageURL, 'missing package name' if components[:name].nil?
|
214
|
+
|
215
|
+
# Create a new PackageURL with validated components
|
216
|
+
type = components[:type] || '' # This ensures type is never nil
|
217
|
+
name = components[:name] || '' # This ensures name is never nil
|
218
|
+
|
219
|
+
new(type: type,
|
220
|
+
name: name,
|
200
221
|
namespace: components[:namespace],
|
201
222
|
version: components[:version],
|
202
223
|
qualifiers: components[:qualifiers],
|
@@ -328,7 +349,13 @@ class PackageURL
|
|
328
349
|
subpath.delete_prefix('/').delete_suffix('/').split('/').each do |segment|
|
329
350
|
next if segment.empty? || segment == '.' || segment == '..'
|
330
351
|
|
331
|
-
|
352
|
+
# Custom encoding for URL fragment segments:
|
353
|
+
# 1. Explicitly encode % as %25 to prevent double-encoding issues
|
354
|
+
# 2. Percent-encode special characters according to URL fragment rules
|
355
|
+
# 3. This ensures proper round-trip encoding/decoding with the parse method
|
356
|
+
segments << segment.gsub(/%|[^A-Za-z0-9\-\._~]/) do |m|
|
357
|
+
m == '%' ? '%25' : format('%%%02X', m.ord)
|
358
|
+
end
|
332
359
|
end
|
333
360
|
|
334
361
|
unless segments.empty?
|
data/packageurl-ruby.gemspec
CHANGED
@@ -17,8 +17,9 @@ Gem::Specification.new do |spec|
|
|
17
17
|
DESCRIPTION
|
18
18
|
|
19
19
|
spec.homepage = 'https://github.com/package-url/packageurl-ruby'
|
20
|
-
spec.required_ruby_version = Gem::Requirement.new('>= 2.
|
20
|
+
spec.required_ruby_version = Gem::Requirement.new('>= 3.2.0')
|
21
21
|
|
22
|
+
spec.license = 'MIT'
|
22
23
|
spec.metadata['homepage_uri'] = spec.homepage
|
23
24
|
spec.metadata['source_code_uri'] = spec.homepage
|
24
25
|
spec.metadata['changelog_uri'] = "#{spec.homepage}/blob/main/CHANGELOG.md"
|
data/sig/package_url.rbs
CHANGED
@@ -1,19 +1,9 @@
|
|
1
|
-
# A package URL, or _purl_, is a URL string used to identify and locate a software package
|
2
|
-
# in a mostly universal and uniform way across
|
3
|
-
# programing languages, package managers, packaging conventions, tools, APIs and databases.
|
4
|
-
#
|
5
|
-
# A purl is a URL composed of seven components:
|
6
|
-
#
|
7
|
-
# ```
|
8
|
-
# scheme:type/namespace/name@version?qualifiers#subpath
|
9
|
-
# ```
|
10
|
-
#
|
11
|
-
# For example,
|
12
|
-
# the package URL for this Ruby package at version 0.1.0 is
|
13
|
-
# `pkg:ruby/mattt/packageurl-ruby@0.1.0`.
|
14
1
|
class PackageURL
|
15
2
|
VERSION: String
|
16
3
|
|
4
|
+
class InvalidPackageURL < ArgumentError
|
5
|
+
end
|
6
|
+
|
17
7
|
def scheme: () -> String
|
18
8
|
attr_reader type: String
|
19
9
|
attr_reader namespace: String?
|
@@ -22,23 +12,32 @@ class PackageURL
|
|
22
12
|
attr_reader qualifiers: Hash[String, String]?
|
23
13
|
attr_reader subpath: String?
|
24
14
|
|
25
|
-
def initialize: (type: String `type`,
|
26
|
-
?namespace: String? namespace,
|
27
|
-
name: String name,
|
28
|
-
?version: String? version,
|
29
|
-
?qualifiers: Hash[String, String]? qualifiers,
|
15
|
+
def initialize: (type: String `type`,
|
16
|
+
?namespace: String? namespace,
|
17
|
+
name: String name,
|
18
|
+
?version: String? version,
|
19
|
+
?qualifiers: Hash[String, String]? qualifiers,
|
30
20
|
?subpath: String? subpath) -> void
|
31
|
-
|
32
|
-
def self.parse: (String string) -> PackageURL?
|
33
21
|
|
34
|
-
def
|
22
|
+
def self.parse: (String string) -> PackageURL
|
23
|
+
|
24
|
+
def to_h: () -> { scheme: String,
|
25
|
+
type: String,
|
26
|
+
namespace: String?,
|
27
|
+
name: String?,
|
28
|
+
version: String?,
|
29
|
+
qualifiers: Hash[String, String]?,
|
30
|
+
subpath: String? }
|
35
31
|
|
36
|
-
# Returns a string representation of the package URL.
|
37
|
-
# Package URL representations are created according to the instructions provided at
|
38
|
-
# https://github.com/package-url/purl-spec/blob/0b1559f76b79829e789c4f20e6d832c7314762c5/PURL-SPECIFICATION.rst#how-to-build-purl-string-from-its-components.
|
39
32
|
def to_s: () -> String
|
40
33
|
|
41
34
|
def deconstruct: () -> Array[String | Hash[String, String] | nil]
|
42
35
|
|
43
|
-
def deconstruct_keys: (Array[Symbol] keys) -> { scheme: String,
|
36
|
+
def deconstruct_keys: (Array[Symbol] keys) -> { scheme: String,
|
37
|
+
type: String,
|
38
|
+
namespace: String?,
|
39
|
+
name: String?,
|
40
|
+
version: String?,
|
41
|
+
qualifiers: Hash[String, String]?,
|
42
|
+
subpath: String? }
|
44
43
|
end
|
metadata
CHANGED
@@ -1,14 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: packageurl-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mattt
|
8
|
-
autorequire:
|
9
8
|
bindir: exe
|
10
9
|
cert_chain: []
|
11
|
-
date:
|
10
|
+
date: 2025-03-21 00:00:00.000000000 Z
|
12
11
|
dependencies: []
|
13
12
|
description: |2
|
14
13
|
A package URL, or purl, is a URL string used to
|
@@ -29,6 +28,7 @@ files:
|
|
29
28
|
- CHANGELOG.md
|
30
29
|
- Gemfile
|
31
30
|
- Gemfile.lock
|
31
|
+
- LICENSE
|
32
32
|
- README.md
|
33
33
|
- Rakefile
|
34
34
|
- Steepfile
|
@@ -39,10 +39,10 @@ files:
|
|
39
39
|
- packageurl-ruby.gemspec
|
40
40
|
- sig/package_url.rbs
|
41
41
|
homepage: https://github.com/package-url/packageurl-ruby
|
42
|
-
licenses:
|
42
|
+
licenses:
|
43
|
+
- MIT
|
43
44
|
metadata:
|
44
45
|
rubygems_mfa_required: 'true'
|
45
|
-
post_install_message:
|
46
46
|
rdoc_options: []
|
47
47
|
require_paths:
|
48
48
|
- lib
|
@@ -50,15 +50,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
50
50
|
requirements:
|
51
51
|
- - ">="
|
52
52
|
- !ruby/object:Gem::Version
|
53
|
-
version: 2.
|
53
|
+
version: 3.2.0
|
54
54
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
55
55
|
requirements:
|
56
56
|
- - ">="
|
57
57
|
- !ruby/object:Gem::Version
|
58
58
|
version: '0'
|
59
59
|
requirements: []
|
60
|
-
rubygems_version: 3.2
|
61
|
-
signing_key:
|
60
|
+
rubygems_version: 3.6.2
|
62
61
|
specification_version: 4
|
63
62
|
summary: Ruby implementation of the package url spec
|
64
63
|
test_files: []
|