I recently moved my dotfiles to a private location. This goes against my previous belief in sharing the knowledge and allowing other to read and learn from my configuration.
Below is why:
find . -type f -name '*.txt' -exec sed -i '' s/123/321/ {} + |
import Data.Char | |
data Request = Request { message :: String } | |
main = getIt | |
getIt :: IO() | |
getIt = do | |
msg <- getLine | |
let r = Request { message = msg } |
#!/bin/bash | |
find /tmp -name '* *' | while read filename; do | |
echo "Converting:$filename" | |
faad -o - "$filename" | lame - "${filename%.m4a}.mp3" | |
done |
Gemfile: | |
source 'http://rubygems.org' | |
gem 'rails', '3.1.3' | |
# Bundle edge Rails instead: | |
# gem 'rails', :git => 'git://github.com/rails/rails.git' | |
gem 'sqlite3' |
Start an instance and specify the metadata with -d. | |
# ec2-run-instances --region us-east-1 -key 'key' --instance-type 'm1.large' ami-1927f370 -d 'this is the data I need' | |
RESERVATION r-67bdc406 608324328795 default | |
INSTANCE i-5ad9aa38 ami-1927f370 pending weaver 0 m1.large 2012-01-06T15:44:47+0000 us-east-1b aki-08ed0761 monitoring-disabled ebs paravirtual xen sg-357c745c default | |
Retrieve the instance hostname. | |
# ec2-describe-instances --region us-east-1 i-5ad9aa38 | grep ^INSTANCE | awk {'print $4'} |
#!/bin/sh | |
# | |
# Modified by bweaver to add root key to ea user | |
# | |
# This script will be executed *after* all the other init scripts. | |
# You can put your own initialization stuff in here if you don't | |
# want to do the full Sys V style init stuff. | |
touch /var/lock/subsys/local |
#!/bin/bash | |
USER=ec2-user | |
echo 'Removing host keys' | |
sudo /bin/rm -rf /etc/ssh/ssh_host*_key* | |
echo 'Removing ec2-user' | |
userdel -f $USER ; /bin/rm -rf /home/$USER |
#!/bin/bash | |
whitelist=ami_rpm_whitelist.txt | |
# List rpms to installed rpmts | |
rpm -q -a > /tmp/installed_rpms | |
# create white list file of rpms installed on the given whitelist | |
for i in `cat $whitelist |tr -d '\r'`; do | |
egrep ^$i /tmp/installed_rpms |
#!/bin/bash | |
# Fucking umask!!! | |
umask 022 | |
# Install epel yum repo | |
rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm | |
# Install deps for ruby build | |
yum install -y gcc rpm-build readline-devel.x86_64 libffi-devel.x86_64 libyaml-devel.x86_64 zlib-devel.x86_64 openssl-devel.x86_64 wget |