ruby-ampache 0.0.8 → 0.0.9

Sign up to get free protection for your applications and to get access to all the features.
data/README.rdoc CHANGED
@@ -18,6 +18,9 @@ example file:
18
18
  AMPACHE_USER="username"
19
19
  AMPACHE_USER_PSW="userpsw"
20
20
 
21
+ #optional (default is /usr/bin/mplayer)
22
+ MPLAYER_PATH="/usr/bin/mplayer"
23
+
21
24
  Simply execute ruby-ampache that should be found in you $PATH after installation
22
25
 
23
26
  == TODO
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.8
1
+ 0.0.9
data/bin/ruby-ampache CHANGED
@@ -87,7 +87,7 @@ end
87
87
 
88
88
  def credits
89
89
  s = <<STR
90
- Ruby-Ampache: Ultra-simple, low-featured command line Ampache player
90
+ Ruby-Ampache: Ultra-simple, low-featured command line Ampache player (uses mplayer for playing)
91
91
  Author: Mattia Gheda aka ghedamat
92
92
  Homepage: http://github.com/ghedamat/ruby-ampache
93
93
  Author-mail: thamayor@gmail.com
@@ -104,6 +104,8 @@ end
104
104
 
105
105
  # MAIN
106
106
  @ar =AmpacheRuby.new(ar_config.get_value('AMPACHE_HOST'),ar_config.get_value('AMPACHE_USER'), ar_config.get_value('AMPACHE_USER_PSW'))
107
+ $options = {}
108
+ $options[:path] = ar_config.get_value('MPLAYER_PATH')
107
109
  @pl = AmpachePlaylist.new
108
110
 
109
111
  while true
data/lib/lib-classes.rb CHANGED
@@ -62,10 +62,9 @@ end
62
62
  class AmpachePlaylist
63
63
  def add(song)
64
64
  if !@pid
65
- options = {}
66
- options[:path] ||= '/usr/bin/mplayer'
65
+ $options[:path] ||= '/usr/bin/mplayer'
67
66
  mplayer_options = "-slave -quiet"
68
- mplayer = "#{options[:path]} #{mplayer_options} \"#{song.url}\""
67
+ mplayer = "#{$options[:path]} #{mplayer_options} \"#{song.url}\""
69
68
  @pid,@stdin,@stdout,@stderr = Open4.popen4(mplayer)
70
69
  begin
71
70
  t = Timeout::timeout(3) do
metadata CHANGED
@@ -1,13 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-ampache
3
3
  version: !ruby/object:Gem::Version
4
- hash: 15
5
4
  prerelease: false
6
5
  segments:
7
6
  - 0
8
7
  - 0
9
- - 8
10
- version: 0.0.8
8
+ - 9
9
+ version: 0.0.9
11
10
  platform: ruby
12
11
  authors:
13
12
  - ghedmat
@@ -15,7 +14,7 @@ autorequire:
15
14
  bindir: bin
16
15
  cert_chain: []
17
16
 
18
- date: 2010-09-30 00:00:00 +02:00
17
+ date: 2010-11-02 00:00:00 +01:00
19
18
  default_executable: ruby-ampache
20
19
  dependencies:
21
20
  - !ruby/object:Gem::Dependency
@@ -26,7 +25,6 @@ dependencies:
26
25
  requirements:
27
26
  - - ">="
28
27
  - !ruby/object:Gem::Version
29
- hash: 3
30
28
  segments:
31
29
  - 0
32
30
  version: "0"
@@ -40,7 +38,6 @@ dependencies:
40
38
  requirements:
41
39
  - - ">="
42
40
  - !ruby/object:Gem::Version
43
- hash: 3
44
41
  segments:
45
42
  - 0
46
43
  version: "0"
@@ -54,7 +51,6 @@ dependencies:
54
51
  requirements:
55
52
  - - ">="
56
53
  - !ruby/object:Gem::Version
57
- hash: 3
58
54
  segments:
59
55
  - 0
60
56
  version: "0"
@@ -68,7 +64,6 @@ dependencies:
68
64
  requirements:
69
65
  - - ">="
70
66
  - !ruby/object:Gem::Version
71
- hash: 3
72
67
  segments:
73
68
  - 0
74
69
  version: "0"
@@ -107,7 +102,6 @@ required_ruby_version: !ruby/object:Gem::Requirement
107
102
  requirements:
108
103
  - - ">="
109
104
  - !ruby/object:Gem::Version
110
- hash: 3
111
105
  segments:
112
106
  - 0
113
107
  version: "0"
@@ -116,7 +110,6 @@ required_rubygems_version: !ruby/object:Gem::Requirement
116
110
  requirements:
117
111
  - - ">="
118
112
  - !ruby/object:Gem::Version
119
- hash: 3
120
113
  segments:
121
114
  - 0
122
115
  version: "0"
@@ -128,5 +121,5 @@ signing_key:
128
121
  specification_version: 3
129
122
  summary: Ruby ampache command line client
130
123
  test_files:
131
- - test/test_ruby-ampache.rb
132
124
  - test/helper.rb
125
+ - test/test_ruby-ampache.rb