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
| #!/bin/bash | |
| # Author: Chmouel Boudjnah <chmouel.boudjnah@rackspace.co.uk> | |
| # Not officially supported by Rackspace only as a best effort basis :) | |
| # Define yes to make it to copy to url to clipboard (via a shortened url | |
| # service) You need to have the software xclip installed in your system. | |
| COPY_URL_TO_CLIPBOARD=yes | |
| # Containers to ignore in the list | |
| CONTAINERS_TO_IGNORE=".CDN_ACCESS_LOGS" |
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
| var input = document.getElementById('myfileinput'); | |
| var files = input.files; | |
| var file = files[i]; | |
| var xhr = new XMLHttpRequest(); | |
| xhr.open('post', '/path/to/destination', true); | |
| xhr.onreadystatechange = function() { | |
| if (this.readyState != 4) { return; } | |
| // request finished - handle response | |
| }; |
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
| /* | |
| The back of the card is rotated 180 degrees from the card itself, giving | |
| the illusion that it really is the back! Unfortunately hiding the back | |
| face of both "faces" doesn't work with webkit builds (requires Snow Leopard!) | |
| but we set it anyway. | |
| */ | |
| .card #back { -webkit-transform: rotateY(180deg); } | |
| .card .face { -webkit-backface-visibility: hidden; } | |
| /* |
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
| module.exports = tree | |
| tree.sync = treeSync | |
| var fs = require("fs") | |
| , path = require("path") | |
| function tree (root, cb) { | |
| fs.lstat(root, function (er, s) { | |
| if (er) return cb(er) | |
| s.name = root |
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
| var express = require('express'); | |
| var sys = require('sys'); | |
| var oauth = require('oauth'); | |
| var app = express.createServer(); | |
| var _twitterConsumerKey = "YOURTWITTERCONSUMERKEY"; | |
| var _twitterConsumerSecret = "YOURTWITTERCONSUMERSECRET"; | |
| function consumer() { |
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 node | |
| var argv = require('optimist') | |
| .usage('Usage: --key=[consumer key] -secret=[consumer secret]') | |
| .demand(['key', 'secret']) | |
| .argv | |
| ; | |
| var OAuth = require('oauth').OAuth; | |
| var Step = require('step'); |
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
| echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc | |
| . ~/.bashrc | |
| mkdir ~/local | |
| mkdir ~/node-latest-install | |
| cd ~/node-latest-install | |
| curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1 | |
| ./configure --prefix=~/local | |
| make install # ok, fine, this step probably takes more than 30 seconds... | |
| curl https://www.npmjs.org/install.sh | sh |
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
| var express = require('express'), | |
| request = require('request'), | |
| BufferList = require('bufferlist').BufferList, | |
| sys = require('sys'); | |
| var app = express.createServer( | |
| express.logger(), | |
| express.bodyDecoder() | |
| ); |
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
| curl -d "track=nodejs,tmpvar,jsdom,carena,cider,conductor" http://stream.twitter.com/1/statuses/filter.json -uUSER:PASS 2> /dev/null | json text -C | while read line; do notify-send -c normal -t 1000 "twitter message" "$line"; done |
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
| curl -d "track=nodejs,tmpvar,jsdom,carena,cider,conductor" http://stream.twitter.com/1/statuses/filter.json -uUSER:PASS 2> /dev/null | json text -C | while read line; do growlnotify -m "$line"; done |
OlderNewer