This file contains 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
Earthquake.init do | |
command :url_show do |m| | |
url = case m[1] | |
when /^\d+$/ | |
"https://twitter.com/#{twitter.status(m[1])['user']['screen_name']}/status/#{m[1]}" | |
else | |
"https://twitter.com/#{m[1][/[^'"]+/]}" | |
end | |
ap url | |
end |
This file contains 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 -*- | |
# notification of im.kayac.com | |
# im.kayac.com経由で通知する | |
require 'im-kayac' | |
username = "foobar" | |
sig = "abababababa" |
This file contains 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
#!perl | |
use strict; | |
use warnings; | |
use utf8; | |
use FindBin; | |
use File::Temp 'tempfile'; | |
use LWP::UserAgent; | |
use Digest::SHA1 'sha1_hex'; |
This file contains 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 perl | |
use strict; | |
use warnings; | |
use FindBin; | |
use lib "$FindBin::Bin/../lib"; | |
use Data::AnomalyDetect; |
This file contains 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 -*- | |
# my output settings | |
# 出力方法をこちらで決定する | |
Earthquake.init do | |
output :tweet do |item| | |
next unless item["text"] | |
info = [] |
This file contains 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
// | |
// lirc_web | |
// v0.0.4 | |
// Alex Bain <[email protected]> | |
// | |
// Requirements | |
// | |
var lirc_node = require('lirc_node'), | |
consolidate = require('consolidate'), |
This file contains 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
app.get('/api/stream', function(req, res) { | |
console.log('connection catched'); | |
var sock = req.socket; | |
conns[sock.fd] = sock; | |
res.on('close', function() { | |
delete conns[sock.fd]; | |
console.log('disconnected: ' + Object.keys(conns).join(", ")); | |
}); | |
sock.on('close', function() { | |
delete conns[sock.fd]; |
This file contains 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
# Description: | |
# 話しかけたら反応します. | |
# | |
# Commands: | |
# hubot 〜〜〜 - ask him! | |
# | |
# Notes: | |
# DON'T DELETE THIS SCRIPT! | |
rules = [ |
This file contains 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 node | |
var io = require('socket.io-client') | |
, argv = require('optimist').argv | |
, w, c, h, u; | |
w = argv.w, c = argv.c, h = argv.h, u = argv.u; | |
w = w || 500; // value for "WARNING" notification | |
c = c || 4000; // value for "CRITICAL" notification |
This file contains 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
package MyApp::Util::Controller; | |
use strict; | |
use warnings; | |
use Class::Method::Modifiers (); | |
use Module::Functions; | |
my %FUNCTIONS; |