Skip to content

Commit

Permalink
add husbando entries and completed implementation of husbandos
Browse files Browse the repository at this point in the history
  • Loading branch information
pixeldesu committed Oct 25, 2014
1 parent b6c535e commit 693e601
Show file tree
Hide file tree
Showing 2 changed files with 81 additions and 4 deletions.
76 changes: 75 additions & 1 deletion husbando.yml
Original file line number Diff line number Diff line change
@@ -1 +1,75 @@

# Free!
- name: Haruka Nanase
series: "Free!"
- name: Makoto Tachibana
series: "Free!"
- name: Nagisa Hazuki
series: "Free!"
- name: Rei Ryugazaki
series: "Free!"
- name: Rin Matsuoka
series: "Free!"
- name: Sousuke Yamazaki
series: "Free!"
- name: Aiichiro Nitori
series: "Free!"
- name: Momotaro Mikoshiba
series: "Free!"
- name: Seijuro Mikoshiba
series: "Free!"
- name: Goro Sasabe
series: "Free!"
- name: Ren Tachibana
series: "Free!"

# Dramatical Murder
- name: Aoba Seragaki
series: Dramatical Murder
- name: Koujaku
series: Dramatical Murder
- name: Noiz
series: Dramatical Murder
- name: Mink
series: Dramatical Murder
- name: Clear
series: Dramatical Murder
- name: Virus
series: Dramatical Murder
- name: Trip
series: Dramatical Murder

# Yowamushi Pedal
- name: Onoda Sakamichi
series: Yowamushi Pedal
- name: Imaizumi Shunsuke
series: Yowamushi Pedal
- name: Naruko Shoukichi
series: Yowamushi Pedal
- name: Kinjou Shingo
series: Yowamushi Pedal
- name: Makishima Yuusuke
series: Yowamushi Pedal
- name: Tadokoro Jin
series: Yowamushi Pedal
- name: Teshima Junta
series: Yowamushi Pedal
- name: Aoyagi Hajime
series: Yowamushi Pedal
- name: Sugimoto Terufumi
series: Yowamushi Pedal
- name: Manami Sangaku
series: Yowamushi Pedal
- name: Toudou Jinpachi
series: Yowamushi Pedal
- name: Juichi Fukutomi
series: Yowamushi Pedal
- name: Shinkai Hayato
series: Yowamushi Pedal
- name: Arakita Yasutomo
series: Yowamushi Pedal
- name: Izumida Touichirou
series: Yowamushi Pedal
- name: Kuroda Yukinari
series: Yowamushi Pedal
- name: Midousuji Akira
series: Yowamushi Pedal
9 changes: 6 additions & 3 deletions waifu.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@

puts "yourwaifu"
puts "-------------------------------"
puts "serving \033[34;1m#{waifu.count}\033[0m entries"
puts "waifu entries: \033[34;1m#{waifu.count}\033[0m"
puts "husbando entries: \033[34;1m#{husbando.count}\033[0m"
puts "filtering with \033[32;1m#{FILTER_WORDS.count}\033[0m entries"
puts "filtering \033[36;1m#{FILTER_USERS.count}\033[0m users"
if keys['tumblr']['enabled']
Expand Down Expand Up @@ -105,14 +106,16 @@ def raise_if_user_filtered!
case object.text
when /husbando?/i
chosen_one = husbando.sample
chosen_one['title'] = "husbando"
else
chosen_one = waifu.sample
chosen_one['title'] = "waifu"
end
puts "[#{Time.new.to_s}] #{object.user.screen_name}: #{chosen_one["name"]} - #{chosen_one["series"]}"
if File.exists? File.expand_path("../img/#{chosen_one["series"]}/#{chosen_one["name"]}.png", __FILE__)
client.update_with_media "@#{object.user.screen_name} Your waifu is #{chosen_one["name"]} (#{chosen_one["series"]})", File.new("img/#{chosen_one["series"]}/#{chosen_one["name"]}.png"), in_reply_to_status:object
client.update_with_media "@#{object.user.screen_name} Your #{chosen_one["title"]} is #{chosen_one["name"]} (#{chosen_one["series"]})", File.new("img/#{chosen_one["series"]}/#{chosen_one["name"]}.png"), in_reply_to_status:object
else
client.update "@#{object.user.screen_name} Your waifu is #{chosen_one["name"]} (#{chosen_one["series"]})", in_reply_to_status:object
client.update "@#{object.user.screen_name} Your #{chosen_one["title"]} is #{chosen_one["name"]} (#{chosen_one["series"]})", in_reply_to_status:object
puts "\033[34;1m[#{Time.new.to_s}] posted without image!\033[0m"
end
if limited
Expand Down

0 comments on commit 693e601

Please sign in to comment.