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
# Update, upgrade and install development tools: | |
apt-get update | |
apt-get -y upgrade | |
apt-get -y install build-essential | |
apt-get -y install git-core | |
# Install rbenv | |
git clone git://github.com/sstephenson/rbenv.git /usr/local/rbenv | |
# Add rbenv to the path: |
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
--type-add | |
html=.mtml |
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
gem: --no-ri --no-rdoc | |
install: --no-rdoc --no-ri | |
update: --no-rdoc --no-ri |
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
# System | |
# install homebrew: http://mxcl.github.com/homebrew/ | |
ruby <(curl -fsSkL raw.github.com/mxcl/homebrew/go) | |
brew install ack | |
brew install bash-completion | |
# Development Tools |
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
[CodeLayout::RequireTidyCode] | |
perltidyrc = ~/.perltidyrc | |
[-Miscellanea::RequireRcsKeywords] | |
[-Documentation::RequirePodAtEnd] | |
[-Documentation::RequirePodSections] |
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
# close Safari! | |
cd ~/Library/Safari | |
cp Bookmarks.plist History.plist ~ # make a backup!! | |
# convert to readable | |
plutil -convert xml1 Bookmarks.plist | |
plutil -convert xml1 History.plist | |
# change with regex |
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
rails_apps_composer new my_app -d starter-app.yml |
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 ci { | |
command="$*" | |
filename="/tmp/ci-$RANDOM-$$" | |
if [ "$1" == "rails" -a "$2" == "new" -a -n "$3" ]; then | |
echo "Initialize new rails app" > $filename | |
echo >> $filename | |
echo "Command:" >> $filename | |
echo " $command" >> $filename | |
$command && cd "$3" && git init && git add . && git commit -a -F $filename |
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
def self.create_index_with_mappings | |
Tire.index Settings.elasticsearch_product_index do | |
create :settings => { | |
:number_of_shards => 1, | |
:number_of_replicas => 1, | |
:analysis => { | |
:filter => { | |
:name_ngrams => { | |
:side => 'front', | |
:type => 'edgeNGram', |
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
LoadModule passenger_module /usr/lib/apache2/modules/mod_passenger.so | |
<IfModule mod_passenger.c> | |
PassengerRoot /usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini | |
PassengerDefaultRuby /usr/local/rvm/wrappers/ruby-2.1.1/bin/ruby | |
PassengerMaxPoolSize 10 | |
PassengerMinInstances 1 | |
PassengerDebugLogFile /var/log/passenger.log | |
PassengerFriendlyErrorPages off | |
</IfModule> |
OlderNewer