Skip to content

Instantly share code, notes, and snippets.

@masui
Created March 11, 2013 14:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save masui/5134566 to your computer and use it in GitHub Desktop.
Save masui/5134566 to your computer and use it in GitHub Desktop.
memoコマンド ちょっとしたことをGyazzに登録するのに使う e.g. % memo 'ちょっとしたことを'
#!/usr/bin/ruby
require 'rubygems'
require 'gyazz'
title = ARGV[0]
if !title then
puts "% memo title"
exit
end
g = Gyazz.new('my_gyazz_memo')
text = "[[#{Time.now.year}/#{Time.now.month}]]"
title = "#{Time.now.strftime('%Y/%m/%d %H:%M:%S')} #{title}"
g.settext(title,text)
url = "http://Gyazz.com/my_gyazz_memo/#{title}"
system "open /Applications/Firefox.app '#{url}'"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment