This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if(typeof(models)=='undefined') | |
this.models = models = new Repository(); | |
var Pinboard = { | |
name : 'Pinboard', | |
ICON : 'http://pinboard.in/favicon.ico', | |
getCurrentUser : function() { | |
if(decodeURIComponent(getCookieString('pinboard.in', 'login')).match(/login=(.*?) /)) | |
return RegExp.$1; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
# haiku tweet / earthquake plugin | |
# | |
Earthquake.init do | |
command :haiku do |m| | |
input(":update #{m[1]} ここで一句、 %s" % [open("http://haiku.jgate.de/"){|f| f.read}]) | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DBQuery.prototype.p = function() { | |
var args = arguments | |
this.forEach(function(e) { | |
var result = {} | |
if(args.length == 0) { | |
result = e | |
} else { | |
for(var i = 0; i < args.length; i++) { | |
var target = e | |
var keys = args[i].split('.') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DBQuery.prototype.p = function() { | |
var args = arguments | |
this.forEach(function(e) { | |
var result = {} | |
if(args.length == 0) { | |
result = e | |
} else { | |
for(var i = 0; i < args.length; i++) { | |
var target = e | |
var keys = args[i].split('.') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
# favstar / earthquakge.gem plugin | |
# | |
# e.g. :favstar #=> your favstar | |
# :favstar who #=> who's favstar | |
# | |
require 'rss' | |
Earthquake.init do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
# favstar / earthquakge.gem plugin | |
# | |
# e.g. :favstar #=> your favstar | |
# :favstar who #=> who's favstar | |
# | |
require 'rss' | |
Earthquake.init do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
# ogyohee tweet / earthquake plugin | |
# | |
# ogyohee: http://shindanmaker.com/152454 | |
# | |
require 'net/http' | |
Earthquake.init do | |
command %r|^:ogyo\s*(.+)*|, :as => :ogyohee do |m| | |
url = "http://shindanmaker.com/152454" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
p() { | |
local pid exit | |
# http://www.filesonic.com/file/703099021 | |
afplay ~/Music/Nyan\ Cat.mp3 & | |
pid=$! | |
trap "kill -9 $pid" INT | |
command $* | |
exit=$? | |
kill -9 $pid | |
trap INT |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
require 'fileutils' | |
require 'digest/md5' | |
def main | |
user = IO.popen("whoami", "r+").gets.chomp | |
file = "/Users/#{user}/Dropbox/Public/gyazo/#{Digest::MD5.hexdigest(Time.now.to_f.to_s)}.png" | |
url = 'https://dl.dropboxusercontent.com/u/2611378/gyazo/' + File.basename(file) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: UTF-8 | |
Earthquake.init do | |
once do | |
user = twitter.info['screen_name'] | |
config[:prompt] = user.c(color_of(user)) + config[:prompt] | |
end | |
end |
OlderNewer