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
require 'formula' | |
class FlumeNg < Formula | |
homepage 'https://github.com/apache/flume' | |
url 'http://archive.cloudera.com/cdh4/cdh/4/flume-ng-1.4.0-cdh4.6.0.tar.gz' | |
#sha1 '2217316f274ff615e9e7dc50f411d95edda60cc3' | |
version "1.4.0-cdh4.6.0" | |
def flume_ng_script | |
<<-EOS.undent |
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
cd ~ | |
sudo apt-get update | |
sudo apt-get install openjdk-7-jre-headless -y | |
### Check http://www.elasticsearch.org/download/ for latest version of ElasticSearch and replace wget link below | |
# NEW WAY / EASY WAY | |
wget https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-1.1.0.deb | |
sudo dpkg -i elasticsearch-1.1.0.deb |
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
{ | |
"title": "Operations Logs", | |
"rows": [ | |
{ | |
"title": "Options", | |
"height": "50px", | |
"editable": true, | |
"collapse": false, | |
"collapsable": true, | |
"panels": [ |
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
topojson = (function() { | |
function merge(topology, arcs) { | |
var arcsByEnd = {}, | |
fragmentByStart = {}, | |
fragmentByEnd = {}; | |
arcs.forEach(function(i) { | |
var e = ends(i); | |
(arcsByEnd[e[0]] || (arcsByEnd[e[0]] = [])).push(i); |
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
library("twitteR") | |
library("wordcloud") | |
library("tm") | |
# You running Windows? It's RSA... you probably are so this is for you. | |
# download.file(url="http://curl.haxx.se/ca/cacert.pem", destfile="cacert.pem") | |
# Go to https://dev.twitter.com/apps and get your keys from your register app there. | |
consumer_key <- 'YOUR CONSUMER KEY' | |
consumer_secret <- 'YOUR SECRET CONSUMER KEY' |
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
Index: php_spl.c | |
=================================================================== | |
--- php_spl.c (revision 290576) | |
+++ php_spl.c (working copy) | |
@@ -359,6 +359,97 @@ | |
} | |
} | |
+ | |
+/* {{{ spl_strrpos_ascii: borrowed from the php ext/standard/string.c */ |
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
// ==UserScript== | |
// @name Assembla Changeset Navigator | |
// @namespace echolibre | |
// @description In assembla, navigate to previous and next changeset | |
// @include https://code.assembla.com/* | |
// @date 2009-03-02 | |
// @version 1.0 | |
// ==/UserScript== | |
var GM_JQ = document.createElement('script'); |
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
%% Map Function | |
%% | |
%% This map function will output the doc.name as the key | |
%% and the doc.value as the value of that key. | |
%% | |
%% In javascript the code would look like: | |
%% | |
%% function(doc) { | |
%% if (doc.name && doc.value) { | |
%% emit(doc.name, doc.value); |
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
function(doc) { | |
if (doc.name && doc.value) { | |
emit(doc.name, doc.value); | |
} | |
} |
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
%% Map Function | |
%% Thanks to Adam Kocoloski (@kocolosk) for this compacted version | |
fun({Doc}) -> | |
case {proplists:get_value(<<"name">>, Doc), proplists:get_value(<<"value">>, Doc)} of | |
{undefined, _} -> | |
ok; | |
{_, undefined} -> | |
ok; | |
{Name, Value} -> | |
Emit(Name, Value); |
OlderNewer