twitchy 0.1.1 → 0.1.2

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: 31af3d06423eafae96cc9dbf8b82607916ce868d
4
- data.tar.gz: 665136e25a38df7a546bc6f9be18e568bfdc5fb3
3
+ metadata.gz: 60a8a5369e9c83ab88f9a7527dae9b906c3c830e
4
+ data.tar.gz: ed8542b21759fb053bf364b08d5766aff0e8634b
5
5
  SHA512:
6
- metadata.gz: 4c8dc487aa64b1cb843c42f742014d0c27f7c3f53feace988bd4864edf44716043f89d8843f270ac02f9544373d5e9015b861b1a4d622e0f75152befa27e8ef4
7
- data.tar.gz: 742a133b912a3bc5b290d301fafd219285856820fd8ce3e618c23aa8e9b2f4d97fa6c90df5a4bbbd80901303cf44166dd88d6cf0b63fc496f0ad40a5163a8758
6
+ metadata.gz: ee02aca4c1c6aa7082857c04401290b5d5f05fefee8095a76f02073d4978b81e0f23413698af47b1376d3285c93f4ce1c0ea23d01cb1a4188ba51bbaba903440
7
+ data.tar.gz: 96ab0109e04712ff00e07e9fbeaf72fa9c5fbb574bcc1ec9a16e8351495d3ed660b09ecc72813073daa542bd2b95ed44e4ac43ed6e2532be62e6aafa6782e07e
data/README.md CHANGED
@@ -20,9 +20,13 @@ Usage: twitchy [options] [channel ..]
20
20
 
21
21
  Requires [`livestreamer`](https://github.com/chrippa/livestreamer) (obviously), and currently the [`colorize`](https://github.com/fazibear/colorize) gem.
22
22
 
23
+ ## Installation
24
+
25
+ `gem install twitchy`
26
+
23
27
  ## Todo
24
28
 
25
- I plan on gemifying this soon. Also, a lot of usage is unclear (pagination in
29
+ ~~I plan on gemifying this soon.~~ Also, a lot of usage is unclear (pagination in
26
30
  archives, quality options, https://github.com/fazibear/colorizeetc).
27
31
 
28
32
  I have greatly reduced API requests from earlier versions, but I'm always keeping an eye out for ways to bring the number of those calls down further. There's a way to get all the videos from subscriptions of a user, but it requires authentication and isn't very flexible, for example, so right now I'm making calls for each requested channel.
@@ -1,4 +1,5 @@
1
1
  require 'json'
2
+ require 'launchy'
2
3
 
3
4
  module Livestreamer
4
5
  @@sort = ["best","source","high","medium","low","mobile","worst"]
@@ -10,14 +11,10 @@ module Livestreamer
10
11
  def self.start_stream(channel, player, quality, chat)
11
12
  stream = "livestreamer -Q -p '#{player}' "\
12
13
  "twitch.tv/#{channel} #{quality} & "
13
- popout_chat = "firefox -new-window "\
14
- "'http://www.twitch.tv/chat/embed"\
15
- "?channel=#{channel}&popout_chat=true' "\
16
- "&> /dev/null & "
17
- cmd = stream
18
- cmd += popout_chat if chat
19
-
20
- exec cmd
14
+ popout_chat = "http://www.twitch.tv/chat/embed"\
15
+ "?channel=#{channel}&popout_chat=true"
16
+ Launchy.open(popout_chat)
17
+ exec stream
21
18
  end
22
19
 
23
20
  def self.start_video(url, player)
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'twitchy'
3
- s.version = '0.1.1'
3
+ s.version = '0.1.2'
4
4
  s.date = '2014-02-11'
5
5
  s.summary = "A Ruby wrapper around livestreamer"
6
6
  s.description = "Twitchy provides for a system to query the TwitchAPI "\
@@ -19,6 +19,7 @@ Gem::Specification.new do |s|
19
19
  "bin/twitchy"
20
20
  ]
21
21
  s.add_runtime_dependency "colorize", "~> 0.6"
22
+ s.add_runtime_dependency "launchy", "~> 2.4"
22
23
  s.homepage = 'http://www.github.com/blkbsstt/twitchy'
23
24
  s.license = 'MIT'
24
25
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: twitchy
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - blkbsstt
@@ -24,6 +24,20 @@ dependencies:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0.6'
27
+ - !ruby/object:Gem::Dependency
28
+ name: launchy
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '2.4'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '2.4'
27
41
  description: Twitchy provides for a system to query the TwitchAPI for use with livestreamer.
28
42
  List online channels, archived videos, and more.
29
43
  email: blkbsstt+twitchy@gmail.com