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
// based on http://shimz.me/blog/node-js/2690 | |
var scriptName = 'index.js'; | |
var separator = '___DATA___'; | |
var http = require('http'), | |
url = require('url'), | |
path = require('path'), | |
fs = require('fs'), | |
port = process.argv[2] || 8888; | |
http.createServer(function(request, response) { |
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
process.on('uncaughtException', function (err) { | |
log.error('uncaughtException : ' + err); | |
}); |
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 FindBIn; | |
use lib "$FindBin::Bin/../../"; | |
use JSON::PP; | |
use Time::Local; |
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
root@sensu:~# diff -u /tmp/graphite.rb /etc/sensu/mutators/graphite.rb | |
--- /tmp/graphite.rb 2014-10-09 10:45:00.774510474 +0900 | |
+++ /etc/sensu/mutators/graphite.rb 2014-10-07 13:21:55.672353581 +0900 | |
@@ -31,8 +31,10 @@ | |
# parse event | |
event = JSON.parse(STDIN.read, :symbolize_names => true) | |
-if ARGV[0] == "-r" || ARGV[0] == "--reverse" | |
- puts event[:check][:output].gsub(event[:client][:name], event[:client][:name].split('.').reverse.join(".")) | |
-else |
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
> diff -u sensu-0.14.0/lib/sensu/client.rb.org sensu-0.14.0/lib/sensu/client.rb | |
--- sensu-0.14.0/lib/sensu\clien.rb.org 2014-10-16 20:40:50 +0900 | |
+++ sensu-0.14.0/lib/sensu\clien.rb 2014-12-08 19:34:36 +0900 | |
@@ -1,5 +1,6 @@ | |
require 'sensu/daemon' | |
require 'sensu/socket' | |
+require 'rufus/scheduler' | |
module Sensu | |
class Client |
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
--- OAuth2Invoker.gs.org 2014-12-12 15:45:41 +0900 | |
+++ OAuth2Invoker.gs 2014-12-12 15:46:04 +0900 | |
@@ -1,7 +1,7 @@ | |
/** | |
* Used for invoked Google App Engine services from Google Apps Script. | |
*/ | |
-function OAuth2Invoker(email, pemBase64, scope){ | |
+function OAuth2Invoker(email, pemBase64, scope, target){ | |
this.post = function(url, payload){ | |
var params = { |
D3.jsの勉強がてらにSTARWARS風な六甲おろしをSVGで作成してみました。
サンプル → bl.ocks.org
解説 → Qiita
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
module['exports'] = function echoHttp (hook) { | |
hook.debug("Debug messages are sent to the debug console"); | |
hook.debug(hook.params); | |
hook.debug(hook.req.path); | |
hook.debug(hook.req.method); | |
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 main | |
import ( | |
"github.com/zenazn/goji" | |
"github.com/zenazn/goji/web" | |
"github.com/google/go-github/github" | |
"net/http" | |
"fmt" | |
"regexp" | |
"io/ioutil" |
OlderNewer