Skip to content

Instantly share code, notes, and snippets.

@tondol
Created February 10, 2014 07:31
Show Gist options
  • Save tondol/8911807 to your computer and use it in GitHub Desktop.
Save tondol/8911807 to your computer and use it in GitHub Desktop.
# -*- coding: utf-8 -*-
require 'net/http'
require 'twitter'
client = Twitter::REST::Client.new {|config|
config.consumer_key = ''
config.consumer_secret = ''
config.oauth_token = ''
config.oauth_token_secret = ''
}
t1 = Time.now
t2 = Time.mktime(2014, 2, 10, 16);
d = t2 - t1
if d >= 0
client.update("!! 卒論提出まで #{(d / 86400).floor} 日と #{(d % 86400 / 3600).round} 時間 !!")
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment