descartes 0.3.9 → 0.3.10

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 270a6e5832ce2155ca5e586a273c36df53ce90a8
4
- data.tar.gz: 5505af70d453c69daff179864040f0ce0ce17d91
3
+ metadata.gz: 844e4ad50eb4f64b97902486f66281c5bc5f32e2
4
+ data.tar.gz: ae57f2b8b6b6aa3a40e0b6e78c717f40f226f6da
5
5
  SHA512:
6
- metadata.gz: 28af8117d44c9faeeeb05fd61cb1c3bdad1f78e2c3a0170075d1efa65c6d407493735a1066f88f8381a55945e4b24d47b6ac46ac530282688c92edab19431b82
7
- data.tar.gz: 6fe1c6ea411d76c5e50ab002e2cdb14bf19ed28fa6e0dc1ae1c35981959fd7898b7d743ea2b8c431f61a0493425c6f98dd9f872b58cd35e30117e74452fd1041
6
+ metadata.gz: cd844a2e4d713565e41ec975289c344e020fc153e93c40f46c8c72d818bc007623fcac2c271315dd165887e8455ed5e140b1e7c4236bbce9a6b28f4bd89e0b60
7
+ data.tar.gz: 8a5633c23864dac0c99e1112aa1b332ed11a247a51099cedf254c6a0449f4c658800c08361f410601b3da2d75789875e6d6f2cfff20d6598d4b2827b6d811428
@@ -0,0 +1,34 @@
1
+ ##
2
+ # DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
3
+ # Version 2, December 2004
4
+ #
5
+ # Everyone is permitted to copy and distribute verbatim or modified
6
+ # copies of this license document, and changing it is allowed as long
7
+ # as the name is changed.
8
+ #
9
+ # DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
10
+ # TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
11
+ #
12
+ # 0. You just DO WHAT THE FUCK YOU WANT TO.
13
+ ##
14
+
15
+ require 'open-uri'
16
+ require 'nokogiri'
17
+
18
+ class Descartes
19
+ class MusicToughts
20
+ include Cinch::Plugin
21
+ match 'music'
22
+
23
+ def execute(m)
24
+ lang = { 'Cookie' => 'lang=it' }
25
+ page = Nokogiri::HTML open('http://musicthoughts.com/t', lang)
26
+
27
+ quote = page.at_xpath('//blockquote//q').text.strip
28
+ author = page.at_xpath('//blockquote//cite').text.strip
29
+
30
+ m.reply quote
31
+ m.reply "- #{author}"
32
+ end
33
+ end
34
+ end
@@ -14,6 +14,6 @@
14
14
 
15
15
  class Descartes
16
16
  def self.version
17
- '0.3.9'
17
+ '0.3.10'
18
18
  end
19
19
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: descartes
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.9
4
+ version: 0.3.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Giovanni Capuano
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-12-11 00:00:00.000000000 Z
11
+ date: 2013-12-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: cinch
@@ -105,6 +105,7 @@ files:
105
105
  - lib/descartes/modules/crunchyroll.rb
106
106
  - lib/descartes/modules/currency.rb
107
107
  - lib/descartes/modules/google.rb
108
+ - lib/descartes/modules/musicthoughts.rb
108
109
  - lib/descartes/modules/quotone.rb
109
110
  - lib/descartes/modules/reply/replies.txt
110
111
  - lib/descartes/modules/reply/sindaco.txt