musical 0.0.4 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.coveralls.yml +1 -0
- data/.gitignore +23 -0
- data/.ruby-version +1 -0
- data/.travis.yml +4 -0
- data/Gemfile +3 -13
- data/Guardfile +24 -0
- data/README.md +59 -0
- data/Rakefile +4 -34
- data/bin/musical +39 -2
- data/lib/musical.rb +33 -25
- data/lib/musical/configuration.rb +18 -0
- data/lib/musical/dvd.rb +80 -100
- data/lib/musical/dvd/chapter.rb +29 -0
- data/lib/musical/dvd/wav.rb +12 -0
- data/lib/musical/util.rb +31 -0
- data/lib/musical/version.rb +4 -0
- data/musical.gemspec +30 -69
- data/spec/musical/configuration_spec.rb +17 -0
- data/spec/musical/dvd/chapter_spec.rb +47 -0
- data/spec/musical/dvd/wav_spec.rb +18 -0
- data/spec/musical/dvd_spec.rb +235 -0
- data/spec/musical_spec.rb +54 -4
- data/spec/spec_helper.rb +19 -8
- data/spec/util_spec.rb +68 -0
- metadata +221 -108
- data/README.rdoc +0 -63
- data/VERSION +0 -1
- data/lib/musical/itunes.rb +0 -31
data/README.rdoc
DELETED
@@ -1,63 +0,0 @@
|
|
1
|
-
= musical
|
2
|
-
|
3
|
-
Musical is a simple tool for your favorite music DVD.
|
4
|
-
You can rip vob file by DVD chapter, convert it to wav file and add it to your iTunes library.
|
5
|
-
|
6
|
-
|
7
|
-
== Install
|
8
|
-
|
9
|
-
1 Musical depends on dvdbackup and ffmpeg. To install them try this for example,
|
10
|
-
brew install dvdbackup
|
11
|
-
brew install ffmpeg
|
12
|
-
|
13
|
-
2 Install gem
|
14
|
-
gem install musical
|
15
|
-
|
16
|
-
|
17
|
-
== Usage
|
18
|
-
Set your DVD and type
|
19
|
-
musical <options>
|
20
|
-
|
21
|
-
Options:
|
22
|
-
--info, -i: Show your DVD data
|
23
|
-
--ignore-convert-sound, -g: Rip data only, NOT convert them to wav file
|
24
|
-
--ignore-use-itunes, -n: NOT add ripped files to iTunes and encode them
|
25
|
-
--dev, -d <s>: Set location of DVD device
|
26
|
-
--title, -t <s>: Set DVD title (default: LIVE)
|
27
|
-
--artist, -a <s>: Set DVD artist (default: Artist)
|
28
|
-
--output, -o <s>: Set location of ripped data (default: ripped)
|
29
|
-
--version, -v: Print version and exit
|
30
|
-
--help, -h: Show this message
|
31
|
-
|
32
|
-
|
33
|
-
When you use iTunes, you should use --title and --artist options. They will help you to manage your music library easily.
|
34
|
-
|
35
|
-
|
36
|
-
== FAQ
|
37
|
-
|
38
|
-
=== On Mac OS X 10.7.x, I cannot install ffmpeg.
|
39
|
-
|
40
|
-
The latest Xcode doesn't include gcc. Install gcc-4.2[https://github.com/kennethreitz/osx-gcc-installer].
|
41
|
-
|
42
|
-
And try this.
|
43
|
-
brew install --use-gcc ffmpeg
|
44
|
-
|
45
|
-
|
46
|
-
=== I got an error, /bin/sh: /usr/bin/pod2man: Permission denied
|
47
|
-
|
48
|
-
/usr/bin/pod2man may not have execute permission.
|
49
|
-
|
50
|
-
Try this.
|
51
|
-
sudo chmod +x /usr/bin/pod2man
|
52
|
-
|
53
|
-
|
54
|
-
=== I got nothing 'musical --info'
|
55
|
-
|
56
|
-
Your DVD may be copy-protected. Try fairmount[http://www.metakine.com/products/fairmount/].
|
57
|
-
|
58
|
-
|
59
|
-
== Copyright
|
60
|
-
|
61
|
-
Copyright (c) 2011 ryo katsuma. See LICENSE.txt for
|
62
|
-
further details.
|
63
|
-
|
data/VERSION
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
0.0.4
|
data/lib/musical/itunes.rb
DELETED
@@ -1,31 +0,0 @@
|
|
1
|
-
module Musical
|
2
|
-
include Appscript
|
3
|
-
|
4
|
-
class ITunes
|
5
|
-
attr_accessor :opts
|
6
|
-
def initialize(options = {})
|
7
|
-
raise "iTunes support works on only Mac OSX" unless RUBY_PLATFORM.include? "darwin"
|
8
|
-
@opts = options # not used yet
|
9
|
-
end
|
10
|
-
|
11
|
-
def its
|
12
|
-
@_its ||= app "iTunes.app"
|
13
|
-
end
|
14
|
-
|
15
|
-
def add(file_path, options = {})
|
16
|
-
wav = its.add MacTypes::FileURL.path(File.expand_path(file_path))
|
17
|
-
return if wav.nil?
|
18
|
-
|
19
|
-
tracks = wav.convert
|
20
|
-
sleep 5 # FIXME
|
21
|
-
tracks.each do |track|
|
22
|
-
[:name, :album, :artist, :track_count, :track_number].each do |key|
|
23
|
-
unless options[key].nil?
|
24
|
-
track.send(key).set options[key]
|
25
|
-
end
|
26
|
-
end
|
27
|
-
end
|
28
|
-
its.delete wav
|
29
|
-
end
|
30
|
-
end
|
31
|
-
end
|