syoboemon 0.1.0 → 0.2.0

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: 5bc2545ff651303f27fa100621220cc1b92352cc
4
- data.tar.gz: e11115495acac859ba7195b2ef490dbf84d99f73
3
+ metadata.gz: 25ffba3bbe818ad92855d8e567d2c3e2e8c0fb08
4
+ data.tar.gz: d0d2e5c90ae1966bd67b928a59fce333f1b3d2cc
5
5
  SHA512:
6
- metadata.gz: 4c17bed5400da04745c0b414eacd66dc1628aaba43ef4d44d890cf9b823842390911c249a5bb8cc6e4711a822ea7be4a95e5909522a62e785ef91054fbd55cb2
7
- data.tar.gz: 0b4e11db7b15c9bc249ad6ae543b0fce81a1cbdecd7b0ebe33abce44bcae184d5bdbd926ae4c739879770f4a0612a841445fe0a2df4b7e30a8bcd28030074312
6
+ metadata.gz: 3e07e666a655c66612ad293734e11d1bd0fc3db807c100c605b1bd30500cac64a3621035636a8988961345bf095618ea33fc18bf06caff8f8e80f265f89f5ac5
7
+ data.tar.gz: 48ba986541bff2ab77b0694af724cf89f141643635a9cdfd7bca796dabc1cfca013b907861388acf82aa3cf22917e605a88ef27e167f8cff4c3bcb955695aa61
data/bin/today_anime ADDED
@@ -0,0 +1,8 @@
1
+ require "./../lib/syoboemon"
2
+
3
+ usr_name = ARGV[0].to_s
4
+
5
+ client = Syoboemon::Client.new
6
+ client.today_programs(usr_name).programs.remove_other_than_anime.each do |prog|
7
+ puts "#{prog.airtime} #{prog.title} [#{prog.broadcaster}]"
8
+ end
@@ -4,9 +4,6 @@
4
4
 
5
5
  # しょぼいカレンダーAPIを利用するためのモジュール
6
6
 
7
- require "rubygems"
8
- require "faraday"
9
-
10
7
  module Syoboemon
11
8
  module APIConnector
12
9
  URL = "http://cal.syoboi.jp"
@@ -55,8 +52,8 @@ module Syoboemon
55
52
  def connector
56
53
  connector ||= Faraday::Connection.new(url: url) do |c|
57
54
  c.request :url_encoded
58
- c.response :logger
59
55
  c.adapter :net_http
56
+ # c.response :logger
60
57
  c.response :raise_error
61
58
  end
62
59
  end
@@ -15,7 +15,7 @@ module Syoboemon
15
15
 
16
16
  def generate_query
17
17
  query = {
18
- usr: @usr.to_s,
18
+ usr: "#{@usr.to_s}",
19
19
  filer: "0",
20
20
  count: "3000",
21
21
  days: "1",
@@ -1,3 +1,3 @@
1
1
  module Syoboemon
2
- VERSION = "0.1.0"
2
+ VERSION = "0.2.0"
3
3
  end
data/lib/syoboemon.rb CHANGED
@@ -1,5 +1,3 @@
1
- $:.unshift File.dirname(__FILE__)
2
-
3
1
  # ruby gems
4
2
  require 'rubygems'
5
3
  require 'faraday'
@@ -7,14 +5,14 @@ require 'happymapper'
7
5
  require "json"
8
6
 
9
7
  # syoboemon ruby files
10
- require "./syoboemon/version" # Syoboemon::VERSION
11
- require "./syoboemon/client" # Syoboemon::Client
12
- require "./syoboemon/api_connector" #Syoboemon::APIConnector
8
+ require "syoboemon/version" # Syoboemon::VERSION
9
+ require "syoboemon/client" # Syoboemon::Client
10
+ require "syoboemon/api_connector" #Syoboemon::APIConnector
13
11
  # Syoboemon::APIResponceParser
14
- require "./syoboemon/api_responce_parser/api_response_parser"
12
+ require "syoboemon/api_responce_parser/api_response_parser"
15
13
  # Syoboemon::QueryGenerator
16
- require "./syoboemon/query_generator/program_detail_search"
17
- require "./syoboemon/query_generator/todays_programs"
14
+ require "syoboemon/query_generator/program_detail_search"
15
+ require "syoboemon/query_generator/todays_programs"
18
16
  # Syoboemon::ProgramInfomationAccessor
19
- require "./syoboemon/program_infomation_accessor/program_detail_search"
20
- require "./syoboemon/program_infomation_accessor/todays_programs"
17
+ require "syoboemon/program_infomation_accessor/program_detail_search"
18
+ require "syoboemon/program_infomation_accessor/todays_programs"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: syoboemon
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - toshiemon18
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-09-21 00:00:00.000000000 Z
11
+ date: 2015-09-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: happymapper
@@ -80,7 +80,7 @@ dependencies:
80
80
  - - ">="
81
81
  - !ruby/object:Gem::Version
82
82
  version: '0'
83
- description: しょぼいカレンダーのAPIラッパッパ. 他の人も作ってたけど自分が欲しい情報引っ張ってくる機能が無かったので自力で実装してる.
83
+ description: "しょぼいカレンダーのAPIラッパッパ. 他の人も作ってたけど自分が欲しい情報引っ張ってくる機能が無かったので自力で実装してる."
84
84
  email:
85
85
  - st12318@gmail.com
86
86
  executables: []
@@ -95,6 +95,7 @@ files:
95
95
  - LICENSE.txt
96
96
  - README.md
97
97
  - Rakefile
98
+ - bin/today_anime
98
99
  - lib/syoboemon.rb
99
100
  - lib/syoboemon/api_connector.rb
100
101
  - lib/syoboemon/api_responce_parser/api_response_parser.rb