ruby-audioinfo 0.4 → 0.5.5

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.
@@ -0,0 +1,5 @@
1
+ # frozen_string_literal: true
2
+
3
+ class AudioInfo
4
+ VERSION = '0.5.5'
5
+ end
@@ -0,0 +1,35 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative 'lib/audioinfo/version'
4
+
5
+ Gem::Specification.new do |spec|
6
+ spec.name = 'ruby-audioinfo'
7
+ spec.version = AudioInfo::VERSION
8
+ spec.authors = ['Guillaume Pierronnet', 'Marcello Barnaba']
9
+ spec.email = ['guillaume.pierronnet@gmail.com']
10
+ spec.summary = 'glues together various audio ruby libraries and presents a unified API to the developer'
11
+ spec.description = "#{spec.summary} Currently, supported formats are: mp3, ogg, mpc, ape, wma, flac, aac, mp4, m4a."
12
+ spec.homepage = 'https://github.com/moumar/ruby-audioinfo'
13
+ spec.license = 'GPL-3.0'
14
+ spec.required_ruby_version = Gem::Requirement.new('>= 2.5.7')
15
+ spec.metadata['homepage_uri'] = spec.homepage
16
+ spec.metadata['source_code_uri'] = spec.homepage
17
+ spec.metadata['changelog_uri'] = 'https://github.com/moumar/ruby-audioinfo/History.txt'
18
+
19
+ # Specify which files should be added to the gem when it is released.
20
+ # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
21
+ spec.files = Dir.chdir(File.expand_path(__dir__)) do
22
+ `git ls-files -z`.split("\x0").reject { |f| f.match(%r{\A(?:test|spec|features)/}) }
23
+ end
24
+ spec.bindir = 'exe'
25
+ spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
26
+ spec.require_paths = ['lib']
27
+
28
+ spec.add_dependency 'apetag', '>= 1.1.4'
29
+ spec.add_dependency 'flacinfo-rb', '>= 0.4'
30
+ spec.add_dependency 'moumar-wmainfo-rb', '>= 0.7'
31
+ spec.add_dependency 'mp4info', '>= 1.7.3'
32
+ spec.add_dependency 'ruby-mp3info', '>= 0.8'
33
+ spec.add_dependency 'ruby-ogginfo', '>= 0.6.13'
34
+ spec.add_dependency 'wavefile', '~> 0.6.0'
35
+ end
metadata CHANGED
@@ -1,182 +1,166 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-audioinfo
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.4'
4
+ version: 0.5.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Guillaume Pierronnet
8
8
  - Marcello Barnaba
9
- autorequire:
10
- bindir: bin
9
+ autorequire:
10
+ bindir: exe
11
11
  cert_chain: []
12
- date: 2013-10-27 00:00:00.000000000 Z
12
+ date: 2021-01-03 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
- name: ruby-mp3info
16
- requirement: !ruby/object:Gem::Requirement
17
- requirements:
18
- - - '>='
19
- - !ruby/object:Gem::Version
20
- version: '0.8'
21
- type: :runtime
22
- prerelease: false
23
- version_requirements: !ruby/object:Gem::Requirement
24
- requirements:
25
- - - '>='
26
- - !ruby/object:Gem::Version
27
- version: '0.8'
28
- - !ruby/object:Gem::Dependency
29
- name: ruby-ogginfo
15
+ name: apetag
30
16
  requirement: !ruby/object:Gem::Requirement
31
17
  requirements:
32
- - - '>='
18
+ - - ">="
33
19
  - !ruby/object:Gem::Version
34
- version: '0.7'
20
+ version: 1.1.4
35
21
  type: :runtime
36
22
  prerelease: false
37
23
  version_requirements: !ruby/object:Gem::Requirement
38
24
  requirements:
39
- - - '>='
25
+ - - ">="
40
26
  - !ruby/object:Gem::Version
41
- version: '0.7'
27
+ version: 1.1.4
42
28
  - !ruby/object:Gem::Dependency
43
- name: mp4info
29
+ name: flacinfo-rb
44
30
  requirement: !ruby/object:Gem::Requirement
45
31
  requirements:
46
- - - '>='
32
+ - - ">="
47
33
  - !ruby/object:Gem::Version
48
- version: 1.7.3
34
+ version: '0.4'
49
35
  type: :runtime
50
36
  prerelease: false
51
37
  version_requirements: !ruby/object:Gem::Requirement
52
38
  requirements:
53
- - - '>='
39
+ - - ">="
54
40
  - !ruby/object:Gem::Version
55
- version: 1.7.3
41
+ version: '0.4'
56
42
  - !ruby/object:Gem::Dependency
57
43
  name: moumar-wmainfo-rb
58
44
  requirement: !ruby/object:Gem::Requirement
59
45
  requirements:
60
- - - '>='
46
+ - - ">="
61
47
  - !ruby/object:Gem::Version
62
48
  version: '0.7'
63
49
  type: :runtime
64
50
  prerelease: false
65
51
  version_requirements: !ruby/object:Gem::Requirement
66
52
  requirements:
67
- - - '>='
53
+ - - ">="
68
54
  - !ruby/object:Gem::Version
69
55
  version: '0.7'
70
56
  - !ruby/object:Gem::Dependency
71
- name: flacinfo-rb
57
+ name: mp4info
72
58
  requirement: !ruby/object:Gem::Requirement
73
59
  requirements:
74
- - - '>='
60
+ - - ">="
75
61
  - !ruby/object:Gem::Version
76
- version: '0.4'
62
+ version: 1.7.3
77
63
  type: :runtime
78
64
  prerelease: false
79
65
  version_requirements: !ruby/object:Gem::Requirement
80
66
  requirements:
81
- - - '>='
67
+ - - ">="
82
68
  - !ruby/object:Gem::Version
83
- version: '0.4'
69
+ version: 1.7.3
84
70
  - !ruby/object:Gem::Dependency
85
- name: apetag
71
+ name: ruby-mp3info
86
72
  requirement: !ruby/object:Gem::Requirement
87
73
  requirements:
88
- - - '>='
74
+ - - ">="
89
75
  - !ruby/object:Gem::Version
90
- version: 1.1.4
76
+ version: '0.8'
91
77
  type: :runtime
92
78
  prerelease: false
93
79
  version_requirements: !ruby/object:Gem::Requirement
94
80
  requirements:
95
- - - '>='
81
+ - - ">="
96
82
  - !ruby/object:Gem::Version
97
- version: 1.1.4
83
+ version: '0.8'
98
84
  - !ruby/object:Gem::Dependency
99
- name: rdoc
85
+ name: ruby-ogginfo
100
86
  requirement: !ruby/object:Gem::Requirement
101
87
  requirements:
102
- - - ~>
88
+ - - ">="
103
89
  - !ruby/object:Gem::Version
104
- version: '3.10'
105
- type: :development
90
+ version: 0.6.13
91
+ type: :runtime
106
92
  prerelease: false
107
93
  version_requirements: !ruby/object:Gem::Requirement
108
94
  requirements:
109
- - - ~>
95
+ - - ">="
110
96
  - !ruby/object:Gem::Version
111
- version: '3.10'
97
+ version: 0.6.13
112
98
  - !ruby/object:Gem::Dependency
113
- name: hoe
99
+ name: wavefile
114
100
  requirement: !ruby/object:Gem::Requirement
115
101
  requirements:
116
- - - ~>
102
+ - - "~>"
117
103
  - !ruby/object:Gem::Version
118
- version: '3.5'
119
- type: :development
104
+ version: 0.6.0
105
+ type: :runtime
120
106
  prerelease: false
121
107
  version_requirements: !ruby/object:Gem::Requirement
122
108
  requirements:
123
- - - ~>
109
+ - - "~>"
124
110
  - !ruby/object:Gem::Version
125
- version: '3.5'
126
- description: |-
127
- ruby-audioinfo glue together various audio ruby libraries and presents a unified
128
- API to the developper. Currently, supported formats are: mp3, ogg, mpc, ape,
129
- wma, flac, aac, mp4, m4a.
111
+ version: 0.6.0
112
+ description: 'glues together various audio ruby libraries and presents a unified API
113
+ to the developer Currently, supported formats are: mp3, ogg, mpc, ape, wma, flac,
114
+ aac, mp4, m4a.'
130
115
  email:
131
116
  - guillaume.pierronnet@gmail.com
132
- - unknown
133
117
  executables: []
134
118
  extensions: []
135
- extra_rdoc_files:
136
- - History.txt
137
- - Manifest.txt
138
- - README.rdoc
119
+ extra_rdoc_files: []
139
120
  files:
121
+ - ".github/workflows/ruby.yml"
122
+ - ".gitignore"
123
+ - ".rubocop.yml"
124
+ - ".rubocop_todo.yml"
125
+ - CODE_OF_CONDUCT.md
126
+ - Gemfile
127
+ - Gemfile.lock
140
128
  - History.txt
141
- - Manifest.txt
142
- - README.rdoc
129
+ - README.md
143
130
  - Rakefile
131
+ - bin/console
132
+ - codecov.yml
144
133
  - lib/audioinfo.rb
145
134
  - lib/audioinfo/album.rb
146
- - lib/audioinfo/mpcinfo.rb
147
135
  - lib/audioinfo/case_insensitive_hash.rb
148
- - test/mpcinfo.rb
149
- - test/test_audioinfo.rb
150
- - test/test_case_insensitive_hash.rb
151
- - test/test_helper.rb
152
- - .gemtest
153
- homepage: http://ruby-audioinfo.rubyforge.org
154
- licenses: []
155
- metadata: {}
156
- post_install_message:
157
- rdoc_options:
158
- - --main
159
- - README.rdoc
136
+ - lib/audioinfo/mpcinfo.rb
137
+ - lib/audioinfo/version.rb
138
+ - ruby-audioinfo.gemspec
139
+ homepage: https://github.com/moumar/ruby-audioinfo
140
+ licenses:
141
+ - GPL-3.0
142
+ metadata:
143
+ homepage_uri: https://github.com/moumar/ruby-audioinfo
144
+ source_code_uri: https://github.com/moumar/ruby-audioinfo
145
+ changelog_uri: https://github.com/moumar/ruby-audioinfo/History.txt
146
+ post_install_message:
147
+ rdoc_options: []
160
148
  require_paths:
161
149
  - lib
162
150
  required_ruby_version: !ruby/object:Gem::Requirement
163
151
  requirements:
164
- - - '>='
152
+ - - ">="
165
153
  - !ruby/object:Gem::Version
166
- version: '0'
154
+ version: 2.5.7
167
155
  required_rubygems_version: !ruby/object:Gem::Requirement
168
156
  requirements:
169
- - - '>='
157
+ - - ">="
170
158
  - !ruby/object:Gem::Version
171
159
  version: '0'
172
160
  requirements: []
173
- rubyforge_project: ruby-audioinfo
174
- rubygems_version: 2.1.5
175
- signing_key:
161
+ rubygems_version: 3.1.2
162
+ signing_key:
176
163
  specification_version: 4
177
- summary: ruby-audioinfo glue together various audio ruby libraries and presents a
178
- unified API to the developper
179
- test_files:
180
- - test/test_audioinfo.rb
181
- - test/test_case_insensitive_hash.rb
182
- - test/test_helper.rb
164
+ summary: glues together various audio ruby libraries and presents a unified API to
165
+ the developer
166
+ test_files: []
data/.gemtest DELETED
File without changes
@@ -1,9 +0,0 @@
1
- History.txt
2
- Manifest.txt
3
- README.rdoc
4
- Rakefile
5
- lib/audioinfo.rb
6
- lib/audioinfo/album.rb
7
- lib/audioinfo/mpcinfo.rb
8
- lib/audioinfo/case_insensitive_hash.rb
9
- test/mpcinfo.rb
@@ -1,46 +0,0 @@
1
- = ruby-audioinfo
2
-
3
- * http://ruby-audioinfo.rubyforge.org
4
- * http://rubyforge.org/projects/ruby-audioinfo/
5
- * https://github.com/moumar/ruby-audioinfo
6
-
7
- by Guillaume Pierronnet
8
-
9
- == DESCRIPTION:
10
-
11
- ruby-audioinfo glue together various audio ruby libraries and presents a unified
12
- API to the developper. Currently, supported formats are: mp3, ogg, mpc, ape,
13
- wma, flac, aac, mp4, m4a.
14
-
15
- == FEATURES/PROBLEMS:
16
-
17
- * beta write support for mp3 and ogg tags (other to be written)
18
- * unified support for tag text-encoding. AudioInfo.new("file", "utf-8") and you're done!
19
- * support for MusicBrainz tags
20
- * AudioInfo::Album class included, which gives an unified way to manage an album in a given directory.
21
-
22
- == SYNOPSIS:
23
-
24
- AudioInfo.open("audio_file.one_of_supported_extensions") do |info|
25
- info.artist # or info["artist"]
26
- info.title # or info["title"]
27
- info.length # playing time of the file
28
- info.bitrate # average bitrate
29
- info.to_h # { "artist" => "artist", "title" => "title", etc... }
30
- end
31
-
32
- == REQUIREMENTS:
33
-
34
- * ruby-mp3info[http://ruby-mp3info.rubyforge.org/]
35
- * ruby-ogginfo[http://ruby-ogginfo.rubyforge.org/]
36
- * MP4Info[http://mp4info.rubyforge.org/]
37
- * flacinfo-rb[http://rubyforge.org/projects/flacinfo-rb/]
38
- * wmainfo-rb[http://rubyforge.org/projects/wmainfo/]
39
-
40
- == INSTALL:
41
-
42
- * sudo gem install ruby-audioinfo
43
-
44
- == LICENSE:
45
-
46
- Ruby
@@ -1,8 +0,0 @@
1
- require File.dirname(__FILE__)+"/../lib/audioinfo/mpcinfo"
2
-
3
- require "pp"
4
-
5
- fn = "file.mpc"
6
- mpc = MpcInfo.new(fn)
7
- pp mpc.id3v2_tag
8
- pp mpc.infos
@@ -1,35 +0,0 @@
1
- require_relative "../lib/audioinfo"
2
- require "minitest/autorun"
3
-
4
- require "fileutils"
5
- require "tmpdir"
6
-
7
- require_relative "test_helper"
8
-
9
- class TestAudioinfo < MiniTest::Unit::TestCase
10
-
11
- FLAC_FILE = "#{Dir.tmpdir}/ruby-audioinfo-test.flac"
12
-
13
- def setup
14
- FileUtils.cp(File.join(SUPPORT_DIR, "440Hz-5sec.flac"), FLAC_FILE)
15
- end
16
-
17
- def test_flac_whitelist
18
- i = AudioInfo.new(FLAC_FILE)
19
- assert_kind_of FlacInfo, i.info
20
- end
21
-
22
- def test_flac_tags_wrapper
23
- i = AudioInfo.new(FLAC_FILE)
24
- assert_kind_of CaseInsensitiveHash, i.info.tags
25
- end
26
-
27
- def test_flac_writing
28
- title = "test with utf8éblèàqsf"
29
- ai = AudioInfo.new(FLAC_FILE)
30
- ai.title = title
31
- ai.close
32
- ai = AudioInfo.new(FLAC_FILE)
33
- assert_equal title, ai.title
34
- end
35
- end
@@ -1,28 +0,0 @@
1
- require "audioinfo"
2
- require "minitest/autorun"
3
-
4
- class TestCaseInsensitiveHash < MiniTest::Unit::TestCase
5
-
6
- def test_string_access
7
- h = CaseInsensitiveHash.new
8
- h["foo"] = "bar"
9
- assert_equal "bar", h["foo"]
10
- end
11
-
12
- def test_symbol_access
13
- h = CaseInsensitiveHash.new
14
- h[:foo] = "bar"
15
- assert_equal "bar", h[:foo]
16
- end
17
-
18
- def test_case_insensitive_access
19
- h = CaseInsensitiveHash.new
20
- h["FOO"] = "bar"
21
- assert_equal "bar", h["foo"]
22
- end
23
-
24
- def test_copy_constructor
25
- h = CaseInsensitiveHash.new({"FOO" => "bar"})
26
- assert_equal "bar", h["foo"]
27
- end
28
- end
@@ -1 +0,0 @@
1
- SUPPORT_DIR = File.expand_path("support", File.dirname(__FILE__))