A line chart with mouseover so that you can read the y-value based on the closest x-value. The x-value is found using d3.mouse and scale.invert. The y-value is then found by bisecting the data.
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
goog.require('goog.Uri'); | |
goog.require('goog.events'); | |
goog.require('goog.json'); | |
goog.require('goog.net.xpc.CrossPageChannel'); | |
goog.global.initOuter = function(url) { | |
goog.events.listen(window, 'load', function() { xpcdemo.initOuter(url); }); | |
}; | |
goog.global.initInner = function() { | |
goog.events.listen(window, 'load', function() { xpcdemo.initInner(); }); |
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
01000000010518d85ccd785c2b8272040e9d8af81525444d039b8970fc02c42475c660e1a400000000d700483045022100cc31a4757fb8c271d904f76a09f49e65699804a4b32879a61cd8cc4cada3078202205e0e1110e6dd066562c190b69c09f6b55dccbb85218e7dbeb87dc04013a81206014c8b5121034ccea3bd0a30e05d9065e4a47683ff86c2b735bc24b5abf682c9421563ea764d21024aa0ff5b42d9e4694b6092183952592f657b71f221120ce522fcdc265038ec6b2102f0a18afb3a68d3329bbee1f154bcf4f29aec0185974ec803ac767a259da764e521020b2af507a116fa025f286004c2704004205a5aff5b4dba99fd08ac24ac300cf254aeffffffff01a0860100000000001976a914d8c446e59afac7863e4698f6d4de9d7a45fbd76988ac00000000 |
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
var redis = require('redis'); | |
var client = redis.createClient(); | |
var pullNotifications = function() { | |
// if notification in list rpop it else block until one is available; timeout=0; | |
client.brpop('_bitcoin_notifications_', '_bitcoin_notifications_', 0, function(e, data) { | |
if(!data.length) return; | |
data = JSON.parse(data[1]); | |
switch(data.type) { |
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
# download libpng 1.4.x (1.5 didn't work yet with GraphicsMagick 1.3.12) | |
./configure --prefix=$HOME/INST && make && make install | |
# download libjpeg | |
./configure --prefix=$HOME/INST && make && make install | |
# download GraphicsMagick | |
CFLAGS=-I$HOME/INST/include LDFLAGS=-L$HOME/INST/lib ./configure --prefix=$HOME/INST --disable-openmp --disable-openmp-slow && make && make install |
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 | |
/** | |
* dependencies: | |
* clientjade (sudo npm install -g clientjade) | |
* chokidar (sudo npm install chokidar) | |
* how to run: | |
* node watch_jade.js | |
* to render template, just call: | |
* jade.render(domNode, templateName, data); | |
*/ |
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
var fs = require('fs'); | |
function removeSockFile(file) { | |
if(fs.existsSync(__dirname+"/tmp/"+file)) { | |
fs.unlinkSync(__dirname+"/tmp/"+file); | |
} | |
} | |
removeSockFile('app.sock'); | |
removeSockFile('main.sock'); |
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
var http = require('http'); | |
var cp = require('child_process'); | |
var httpProxy = require('http-proxy'); | |
var sentinelChild = cp.spawn('node', ['app.js'], {stdio: 'inherit'}); | |
var agentChild = cp.spawn('node', ['agent/agent.js'], {stdio: 'inherit'}); | |
var agent = new httpProxy.HttpProxy({ | |
target: { | |
host: 'localhost', |
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
➜ team-unknown git:(master) jitsu deploy | |
info: Welcome to Nodejitsu nko3-team-unknown | |
info: jitsu v0.11.3, node v0.8.14 | |
info: It worked if it ends with Nodejitsu ok | |
info: Executing command deploy | |
info: Analyzing application dependencies in node server.js | |
info: Creating snapshot 0.0.4 | |
info Uploading: [=============================] 100% | |
error: Error running command deploy | |
error: Nodejitsu Error (500): Internal Server Error |