mkdir -p ~/.vim/autoload ~/.vim/bundle && \
curl -LSso ~/.vim/autoload/pathogen.vim https://tpo.pe/pathogen.vim
Ensure that pathogen.vim ends up in ~/.vim/autoload
mkdir ~/.vim/colors
| (ns hello-clojure-web.core | |
| (:use ring.adapter.jetty)) | |
| (defn handler [req] | |
| {:status 200 | |
| :headers {"Content-Type" "text/html"} | |
| :body "Hello Clojure Web!" }) | |
| (run-jetty handler {:port 8080}) |
| sudo add-apt-repository ppa:groovy-dev/grails | |
| sudo apt-get update | |
| sudo apt-get install grails-ppa | |
| #to add grails 2.0.x | |
| sudo apt-get install grails 2.0.x | |
| #to add grails 1.3.9 | |
| sudo apt-get install grails-1.3.9 |
| # MySQL. Versions 4.1 and 5.0 are recommended. | |
| # | |
| # Install the MySQL driver: | |
| # gem install mysql2 | |
| # | |
| # And be sure to use new-style password hashing: | |
| # http://dev.mysql.com/doc/refman/5.0/en/old-client.html | |
| development: | |
| adapter: mysql2 | |
| encoding: utf8 |
| The "size" field shows total reserved GC heap size in MB, which includes all generations (including PermGen). | |
| "32-bits Oops" means the shift is zero; otherwise it'd be non-zero. | |
| If UseCompressedOops is false, or if the heap is too big to use compressed oops, then PrintCompressedOopsMode won't print anything. The -Xmx32g example below show that ergonomics didn't set UseCompressedOops to true. | |
| If the heap is too big, HotSpot would print a warning message and set UseCompressedOops to false. |
| #!/usr/bin/env python2 | |
| # git-branch-io -- show incoming and outgoing commits | |
| # | |
| # Place this file somewhere in your PATH. | |
| # | |
| # Usage: git branch-io [branch] | |
| # | |
| # If branch is not given the current branch will be used. The script | |
| # prints out how many commits should go in either direction to bring |
| { | |
| "from" : 0, | |
| "query" : { | |
| "filtered" : { "query" : { "query_string" : { "query" : "jboss server" } }, | |
| "filter": { | |
| "and" : [ | |
| {"range" : { "date" : {"from":"2007-07-25","to":"2010-12-16"}}}, | |
| {"terms" : { "_index" : ["weld"]}}, | |
| {"terms" : {"mail_list" : ["dev"]}}, | |
| {"terms" : {"from.not_analyzed" : [ "Galder Zamarreno <galder.zamarreno@redhat.com>","Pete Muir <pmuir@redhat.com>"]}} |
| (ns distblast-cluster.vagrant | |
| (:require [pallet.compute :as compute] | |
| [pallet.phase :as phase] | |
| [pallet.core :as core] | |
| [pallet.utils :as utils] | |
| [pallet.compute.node-list :as node-list] | |
| [pallet.action.exec-script :as exec-script])) | |
| (defn test-script [session] | |
| (-> session |
| #!/bin/bash | |
| function jsonval { | |
| temp=`echo $json | sed 's/\\\\\//\//g' | sed 's/[{}]//g' | awk -v k="text" '{n=split($0,a,","); for (i=1; i<=n; i++) print a[i]}' | sed 's/\"\:\"/\|/g' | sed 's/[\,]/ /g' | sed 's/\"//g' | grep -w $prop` | |
| echo ${temp##*|} | |
| } | |
| json=`curl -s -X GET http://twitter.com/users/show/$1.json` | |
| prop='profile_image_url' | |
| picurl=`jsonval` |
| # | |
| # Wide-open CORS config for nginx | |
| # | |
| location / { | |
| if ($request_method = 'OPTIONS') { | |
| add_header 'Access-Control-Allow-Origin' '*'; | |
| # |