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
for name in $(find . -type f | xargs -I {} basename {} | sort | uniq -d); do find . -type f -name "$name"; done |
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
#!/bin/sh | |
# E | |
wget -qO - http://packages.elasticsearch.org/GPG-KEY-elasticsearch | sudo apt-key add - | |
echo 'deb http://packages.elasticsearch.org/elasticsearch/1.4/debian stable main' | sudo tee /etc/apt/sources.list.d/elasticsearch.list | |
sudo update-rc.d elasticsearch defaults 95 10 | |
sudo /etc/init.d/elasticsearch start | |
# L | |
echo 'deb http://packages.elasticsearch.org/logstash/1.4/debian stable main' | sudo tee /etc/apt/sources.list.d/logstash.list |
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
for id in $(aws ec2 describe-instances | jq -c '.Reservations[].Instances[] | select(.State.Name == "running") | .BlockDeviceMappings[].Ebs.VolumeId' | sed 's/"//g'); do aws ec2 describe-volumes | jq -c ".Volumes[] | select(.VolumeId == \"$id\") | .Size"; | done awk '{s+=$1} END {print s}' |
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 --git a/growthforecast.pl b/growthforecast.pl | |
index 9a32a1d..7babee9 100755 | |
--- a/growthforecast.pl | |
+++ b/growthforecast.pl | |
@@ -9,7 +9,7 @@ use File::Basename; | |
use Getopt::Long; | |
use Plack::Loader; | |
use Plack::Builder; | |
-use Plack::Builder::Conditionals; | |
+use Plack::Middleware::Conditional; |
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
#!/bin/sh | |
pear list-upgrades |grep -v 'No upgrades available' |
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
source 'https://rubygems.org' | |
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails' | |
gem 'rails', github: 'rails/rails' | |
group :assets do | |
gem 'uglifier', '>= 1.0.3' | |
end | |
gem 'journey', github: 'rails/journey' | |
gem 'activerecord-deprecated_finders', github: 'rails/activerecord-deprecated_finders' |
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
#!/bin/bash | |
for f in app/tmp/{logs,cache/{,persistent,models}}; do mkdir -p $f; chmod -R 777 $f; touch $f/empty; done |
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 ruby | |
# encoding: utf-8 | |
require 'nokogiri' | |
@doc = Nokogiri::HTML::DocumentFragment.parse <<-EOHTML | |
<table></table> | |
EOHTML | |
@tables = @doc.xpath("table") |
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
#!/bin/sh | |
# Ref. https://developer.mozilla.org/en/Simple_Thunderbird_build | |
sudo apt-get build-dep thunderbird | |
sudo apt-get install mercurial yasm libcurl4-openssl-dev |
NewerOlder