mime-types-data 3.2024.1105 → 3.2026.0127
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/CHANGELOG.md +794 -0
- data/CODE_OF_CONDUCT.md +166 -0
- data/CONTRIBUTING.md +213 -0
- data/CONTRIBUTORS.md +54 -0
- data/{Licence.md → LICENCE.md} +1 -1
- data/Manifest.txt +7 -19
- data/README.md +42 -34
- data/Rakefile +52 -116
- data/SECURITY.md +24 -5
- data/data/content_type_mime.db +240 -48
- data/data/ext_mime.db +1611 -1204
- data/data/mime-types.json +1 -1
- data/data/mime.content_type.column +535 -57
- data/data/mime.docs.column +478 -0
- data/data/mime.encoding.column +478 -0
- data/data/mime.flags.column +556 -78
- data/data/mime.friendly.column +478 -0
- data/data/mime.pext.column +478 -0
- data/data/mime.spri.column +0 -0
- data/data/mime.use_instead.column +478 -0
- data/data/mime.xrefs.column +586 -108
- data/lib/mime/types/data.rb +1 -1
- data/licences/dco.txt +34 -0
- metadata +33 -105
- data/Code-of-Conduct.md +0 -128
- data/Contributing.md +0 -203
- data/History.md +0 -615
- data/types/application.yaml +0 -18989
- data/types/audio.yaml +0 -1753
- data/types/chemical.yaml +0 -71
- data/types/conference.yaml +0 -9
- data/types/drawing.yaml +0 -15
- data/types/example.yaml +0 -1
- data/types/font.yaml +0 -65
- data/types/haptics.yaml +0 -28
- data/types/image.yaml +0 -1329
- data/types/message.yaml +0 -247
- data/types/model.yaml +0 -454
- data/types/multipart.yaml +0 -187
- data/types/text.yaml +0 -1281
- data/types/video.yaml +0 -1158
- data/types/world.yaml +0 -8
data/Rakefile
CHANGED
|
@@ -4,51 +4,36 @@ require "rubygems"
|
|
|
4
4
|
require "hoe"
|
|
5
5
|
require "rake/clean"
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
Hoe.plugin :
|
|
10
|
-
|
|
7
|
+
$LOAD_PATH.unshift("lib", "support")
|
|
8
|
+
|
|
9
|
+
Hoe.plugin :halostatue
|
|
10
|
+
|
|
11
|
+
Hoe.plugins.delete :debug
|
|
12
|
+
Hoe.plugins.delete :newb
|
|
13
|
+
Hoe.plugins.delete :publish
|
|
14
|
+
Hoe.plugins.delete :signing
|
|
11
15
|
|
|
12
16
|
Hoe.spec "mime-types-data" do
|
|
13
17
|
developer("Austin Ziegler", "halostatue@gmail.com")
|
|
14
18
|
|
|
15
|
-
self.
|
|
16
|
-
self.readme_file = "README.md"
|
|
17
|
-
|
|
18
|
-
license "MIT"
|
|
19
|
+
self.trusted_release = ENV["rubygems_release_gem"] == "true"
|
|
19
20
|
|
|
20
21
|
require_ruby_version ">= 2.0"
|
|
21
22
|
|
|
22
|
-
|
|
23
|
+
license "MIT"
|
|
24
|
+
|
|
25
|
+
spec_extras[:metadata] = ->(val) {
|
|
26
|
+
val["rubygems_mfa_required"] = "true"
|
|
27
|
+
}
|
|
23
28
|
|
|
24
29
|
extra_dev_deps << ["hoe", "~> 4.0"]
|
|
25
|
-
extra_dev_deps << ["hoe-
|
|
26
|
-
extra_dev_deps << ["
|
|
27
|
-
extra_dev_deps << ["hoe-git2", "~> 1.7"]
|
|
28
|
-
extra_dev_deps << ["hoe-rubygems", "~> 1.0"]
|
|
29
|
-
extra_dev_deps << ["mime-types", ">= 3.4.0", "< 4"]
|
|
30
|
+
extra_dev_deps << ["hoe-halostatue", "~> 2.0"]
|
|
31
|
+
extra_dev_deps << ["mime-types", "> 3.6.2", "< 5"]
|
|
30
32
|
extra_dev_deps << ["nokogiri", "~> 1.6"]
|
|
31
33
|
extra_dev_deps << ["rake", ">= 10.0", "< 14"]
|
|
32
34
|
extra_dev_deps << ["standard", "~> 1.0"]
|
|
33
35
|
end
|
|
34
36
|
|
|
35
|
-
$LOAD_PATH.unshift "lib"
|
|
36
|
-
$LOAD_PATH.unshift "support"
|
|
37
|
-
|
|
38
|
-
def new_version
|
|
39
|
-
version =
|
|
40
|
-
IO.read("lib/mime/types/data.rb").scan(/VERSION = ['"](\d\.\d{4}\.\d{4}(?:\.\d+)?)['"]/).flatten.first
|
|
41
|
-
|
|
42
|
-
major = Gem::Version.new(version).canonical_segments.first
|
|
43
|
-
minor = Date.today.strftime("%Y.%m%d")
|
|
44
|
-
|
|
45
|
-
"#{major}.#{minor}"
|
|
46
|
-
end
|
|
47
|
-
|
|
48
|
-
def release_header
|
|
49
|
-
"#{new_version} / #{Date.today.strftime("%Y-%m-%d")}"
|
|
50
|
-
end
|
|
51
|
-
|
|
52
37
|
namespace :mime do
|
|
53
38
|
desc "Download the current MIME type registrations from IANA."
|
|
54
39
|
task :iana, [:destination] do |_, args|
|
|
@@ -56,112 +41,63 @@ namespace :mime do
|
|
|
56
41
|
IANARegistry.download(to: args.destination)
|
|
57
42
|
end
|
|
58
43
|
|
|
59
|
-
desc "Download the current MIME type configuration from Apache."
|
|
44
|
+
desc "Download the current MIME type configuration from Apache httpd."
|
|
60
45
|
task :apache, [:destination] do |_, args|
|
|
61
46
|
require "apache_mime_types"
|
|
62
47
|
ApacheMIMETypes.download(to: args.destination)
|
|
63
48
|
end
|
|
49
|
+
|
|
50
|
+
desc "Download the current MIME type configuration from Apache Tika."
|
|
51
|
+
task :tika, [:destination] do |_, args|
|
|
52
|
+
require "tika_mime_types"
|
|
53
|
+
TikeMIMETypes.download(to: args.destination)
|
|
54
|
+
end
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
task :version do
|
|
58
|
+
require "mime/types/data"
|
|
59
|
+
puts MIME::Types::Data::VERSION
|
|
64
60
|
end
|
|
65
61
|
|
|
66
62
|
namespace :release do
|
|
67
|
-
|
|
68
|
-
task
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
63
|
+
desc "Prepare a new release"
|
|
64
|
+
task :prepare do
|
|
65
|
+
require "prepare_release"
|
|
66
|
+
|
|
67
|
+
PrepareRelease.new
|
|
68
|
+
.download_and_convert
|
|
69
|
+
.write_updated_version
|
|
70
|
+
.write_updated_history
|
|
71
|
+
.rake_git_manifest
|
|
72
|
+
.rake_gemspec
|
|
76
73
|
end
|
|
77
74
|
|
|
78
75
|
desc "Prepare a new release for use with GitHub Actions"
|
|
79
76
|
task :gha do
|
|
80
77
|
require "prepare_release"
|
|
81
78
|
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
end
|
|
90
|
-
|
|
91
|
-
desc "Prepare a new automatic release"
|
|
92
|
-
task automatic: :__pull do
|
|
93
|
-
if system("git diff --quiet --exit-code") == false
|
|
94
|
-
Rake::Task["release:__prepare"].invoke
|
|
95
|
-
Rake::Task["gemspec"].invoke
|
|
96
|
-
Rake::Task["release:__commit"].invoke
|
|
97
|
-
else
|
|
98
|
-
warn "No changes detected."
|
|
99
|
-
end
|
|
79
|
+
PrepareRelease.new
|
|
80
|
+
.download_and_convert
|
|
81
|
+
.write_updated_version
|
|
82
|
+
.write_updated_history
|
|
83
|
+
.rake_git_manifest
|
|
84
|
+
.rake_gemspec
|
|
85
|
+
.as_gha_vars
|
|
100
86
|
end
|
|
101
87
|
end
|
|
102
88
|
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
task :json, [:source, :destination, :multiple_files] do |_, args|
|
|
107
|
-
require "convert"
|
|
108
|
-
Convert.from_yaml_to_json(from: args.source, to: args.destination, multiple_files: args.multiple_files)
|
|
109
|
-
end
|
|
110
|
-
|
|
111
|
-
desc "Convert from YAML to Columnar"
|
|
112
|
-
task :columnar, [:source, :destination] do |_, args|
|
|
113
|
-
require "convert/columnar"
|
|
114
|
-
Convert::Columnar.from_yaml_to_columnar(from: args.source, to: args.destination)
|
|
115
|
-
end
|
|
116
|
-
|
|
117
|
-
desc "Convert from YAML to mini_mime db format"
|
|
118
|
-
task :mini_mime, [:source, :destination] do |_, args|
|
|
119
|
-
require "convert/mini_mime_db"
|
|
120
|
-
Convert::MiniMimeDb.from_yaml_to_mini_mime(from: args.source, to: args.destination)
|
|
121
|
-
end
|
|
122
|
-
end
|
|
89
|
+
desc "Full data conversion for release"
|
|
90
|
+
task :convert do
|
|
91
|
+
require "prepare_release"
|
|
123
92
|
|
|
124
|
-
|
|
125
|
-
desc "Convert from JSON to YAML"
|
|
126
|
-
task :yaml, [:source, :destination, :multiple_files] do |_, args|
|
|
127
|
-
require "convert"
|
|
128
|
-
Convert.from_json_to_yaml(from: args.source, to: args.destination, multiple_files: args.multiple_files)
|
|
129
|
-
end
|
|
130
|
-
end
|
|
93
|
+
PrepareRelease.new.convert_types
|
|
131
94
|
end
|
|
132
95
|
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
file = IO.read("lib/mime/types/data.rb")
|
|
137
|
-
updated = file.sub(/VERSION = ['"][.0-9]+['"]/, %(VERSION = "#{new_version}"))
|
|
138
|
-
|
|
139
|
-
IO.write("lib/mime/types/data.rb", updated)
|
|
140
|
-
end
|
|
141
|
-
|
|
142
|
-
desc "Update the history file with automatic release notes"
|
|
143
|
-
task :history do
|
|
144
|
-
history = IO.read("History.md")
|
|
145
|
-
|
|
146
|
-
if !/^## #{release_header}$/.match?(history)
|
|
147
|
-
note = <<-NOTE
|
|
148
|
-
<!-- automatic-release -->
|
|
149
|
-
|
|
150
|
-
## #{release_header}
|
|
151
|
-
|
|
152
|
-
- Updated the Apache and IANA media registry entries as of release date.
|
|
153
|
-
NOTE
|
|
154
|
-
|
|
155
|
-
updated = history.sub("<!-- automatic-release -->\n", note)
|
|
156
|
-
|
|
157
|
-
IO.write("History.md", updated)
|
|
158
|
-
end
|
|
159
|
-
end
|
|
96
|
+
task "convert:upgrade" do
|
|
97
|
+
require "convert"
|
|
98
|
+
Convert.from_yaml_to_yaml
|
|
160
99
|
end
|
|
161
100
|
|
|
162
|
-
desc "Default conversion from YAML to JSON and Columnar"
|
|
163
|
-
task convert: ["convert:yaml:json", "convert:yaml:columnar", "convert:yaml:mini_mime"]
|
|
164
|
-
|
|
165
101
|
Rake::Task["gem"].prerequisites.unshift("convert")
|
|
166
102
|
Rake::Task["gem"].prerequisites.unshift("git:manifest")
|
|
167
103
|
Rake::Task["gem"].prerequisites.unshift("gemspec")
|
data/SECURITY.md
CHANGED
|
@@ -1,7 +1,26 @@
|
|
|
1
|
-
# mime-types Security
|
|
1
|
+
# mime-types-data Security
|
|
2
2
|
|
|
3
|
-
## Security
|
|
3
|
+
## LLM-Generated Security Report Policy
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
Absolutely no security reports will be accepted that have been generated by LLM
|
|
6
|
+
agents.
|
|
7
|
+
|
|
8
|
+
## Supported Versions
|
|
9
|
+
|
|
10
|
+
Security reports are accepted for the most recent major release, with a limited
|
|
11
|
+
window of support after the initial major release.
|
|
12
|
+
|
|
13
|
+
- Bug reports will be accepted up to three months after release.
|
|
14
|
+
- Security reports will be accepted up to six months after release.
|
|
15
|
+
|
|
16
|
+
All issues raised must be demonstrated on the minimum supported Ruby version.
|
|
17
|
+
|
|
18
|
+
## Reporting a Vulnerability
|
|
19
|
+
|
|
20
|
+
Report vulnerabilities via the [Tidelift security contact][tidelift]. Tidelift
|
|
21
|
+
will coordinate the fix and disclosure.
|
|
22
|
+
|
|
23
|
+
Alternatively, create a [private vulnerability report][advisory] with GitHub.
|
|
24
|
+
|
|
25
|
+
[advisory]: https://github.com/halostatue/mime-types-data/security/advisories/new
|
|
26
|
+
[tidelift]: https://tidelift.com/security
|