mdisc 0.1.5 → 0.1.6

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 517516d1caae450b750f38cc40ba6f3c59589378
4
- data.tar.gz: 2f76a77f18bd3db546c4b0af4fe02b44eaf9516f
3
+ metadata.gz: e49de2b1362160c9308575986d61058e1be29b9a
4
+ data.tar.gz: 1b313283837bb81b26433fe12339a82c4318158f
5
5
  SHA512:
6
- metadata.gz: 017a94632c0254a20c380fa84cb3175d6c6a14c794ce109328d9f336c75d9acc6bbf7ecdcb9db35bdaf96bb5e4ce62d7e09c61adf49ff767b9c4a8cfc0dc1bad
7
- data.tar.gz: 88c70d888f818e60a16d64c939cf9b7f77c044c2b3358ddf6c0d6fbcbb1b5a4993a925dffe316992cc215f6708792cbcd25f3c6323b542bac45b60060b4f7764
6
+ metadata.gz: 211dc7438ebb69ea91f14d9d00056a4e6701116109efeefee36e2759d9cd6d6f0dec6407e9ac5dec0aafc7e0b12ea754d2368babc4d83fb2fc2984bccf75d63b
7
+ data.tar.gz: b655d094f5341668f0bb2bf39d10c22a53b156b2e206814b08b872b88282130f5beda1fa4c021df092c1a4ccec0c2c46095b1a2716e6f17f5cec2ec0f3f0bd18
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Mdisc
2
2
 
3
- ![Mdisc](http://cl.ly/Y6Qz/mdisc.png)
3
+ ![Mdisc](http://cl.ly/Yy0o/mdisc.png)
4
4
 
5
5
  Mdisc, built with Ruby 2.1, is a command line music player that wirelessly plugs in Netease music(http://music.163.com).
6
6
 
@@ -47,11 +47,12 @@ class Menu
47
47
  @playlists = []
48
48
  @account = {}
49
49
  @carousel = ->(left, right, x){x < left ? right : (x > right ? left : x)}
50
-
51
- read_data
52
50
  end
53
51
 
54
52
  def start
53
+ check_player
54
+ read_data
55
+
55
56
  ui.build_menu(@datatype, @title, @datalist, @offset, @index, @step)
56
57
  @stack.push [@datatype, @title, @datalist, @offset, @index, @step]
57
58
 
@@ -381,6 +382,12 @@ class Menu
381
382
 
382
383
  private
383
384
 
385
+ def check_player
386
+ if !system('which mpg123 > /dev/null 2>&1')
387
+ raise '!!!Please install `mpg123` before using Mdisc!!!'
388
+ end
389
+ end
390
+
384
391
  def check_dir
385
392
  dir = "#{ENV['HOME']}/.mdisc"
386
393
  unless Dir.exist? dir
@@ -1,3 +1,3 @@
1
1
  module Mdisc
2
- VERSION = '0.1.5'
2
+ VERSION = '0.1.6'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mdisc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.5
4
+ version: 0.1.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rick Yu
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-05 00:00:00.000000000 Z
11
+ date: 2014-12-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler