Every couple of weeks, I hear someone complaining about some difficulties with Bundler. Yesterday, it happened twice. But somehow I just never have those difficulties. I'm not saying Bundler is perfect; certainly in its early days it wasn't even close. But for the past two years it's been incredibly solid and trouble-free for me, and I think a large part of the reason is the way I use it. Bundler arguably does too much, and just as with Git, a big part of it is knowing what not to do, and configuring things to avoid the trouble spots.
This file contains hidden or 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
build_package_patch_ruby_railsexpress() { | |
fetch_git rvm-patchsets git://github.com/skaes/rvm-patchsets.git master | |
for p in rvm-patchsets/patches/ruby/1.9.3/p551/railsexpress/* ; do | |
patch -p1 < $p | |
done | |
} | |
install_package "yaml-0.1.4" "http://pyyaml.org/download/libyaml/yaml-0.1.4.tar.gz#36c852831d02cf90508c29852361d01b" | |
install_package "ruby-1.9.3-p551" "http://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p551.tar.gz" patch_ruby_railsexpress autoconf standard |
This file contains hidden or 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
build_package_patch_ruby_railsexpress() { | |
fetch_git rvm-patchsets git://github.com/skaes/rvm-patchsets.git master | |
for p in rvm-patchsets/patches/ruby/1.9.3/p550/railsexpress/* ; do | |
patch -p1 < $p | |
done | |
} | |
install_package "yaml-0.1.4" "http://pyyaml.org/download/libyaml/yaml-0.1.4.tar.gz#36c852831d02cf90508c29852361d01b" | |
install_package "ruby-1.9.3-p550" "http://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p550.tar.gz" patch_ruby_railsexpress autoconf standard |
This file contains hidden or 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
RED="\[\033[0;31m\]" | |
YELLOW="\[\033[0;33m\]" | |
GREEN="\[\033[0;32m\]" | |
WHITE="\[\033[1;37m\]" | |
BLACK="\[\033[0;30m\]" | |
OFF="\[\033[0m\]" | |
# Download git-completion from https://github.com/rtomayko/dotfiles/blob/rtomayko/.bash_completion.d/git-completion.bash | |
source /usr/local/etc/bash_completion.d/git-completion.bash | |
export PS1="$RED\$(~/.rvm/bin/rvm-prompt) $GREEN\w$YELLOW\$(__git_ps1 "[%s]")$OFF \$ " |
This file contains hidden or 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
var funcs = ['functionOne', 'functionTwo', 'functionThree']; | |
for(func in funcs) { | |
(function (func_name) { | |
window[func_name] = function () { | |
console.log('My name is ' + func_name); | |
} | |
})(funcs[func]); | |
} | |
functionOne(); |
thor install app_create.thor
Make sure that the templates__generic_gemfile.erb is renamed and moved to ~/.thor/templates/generic_gemfile.erb
Then you can run thor list
to verify that the script was installed successfully. If the command appears in the output, you should be good to run thor app:create APP_NAME
.
This file contains hidden or 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
[alias] | |
s = show | |
b = branch | |
ba = branch -a | |
ci = commit | |
cp = cherry-pick | |
cia = commit -a --amend | |
cim = commit -am | |
co = checkout | |
cob = checkout -b |
This file contains hidden or 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src='http://ajax.googleapis.com/ajax/libs/jquery/1.5.2/jquery.min.js'></script> | |
<script> | |
$(document).ready(function(){ | |
function debug(str){ $("#debug").append("<p>"+str+"</p>"); }; | |
if(typeof WebSocket === 'undefined') { | |
alert("Your browser does not support websockets.") | |
} |
This file contains hidden or 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
filetype off | |
set rtp+=~/.vim/bundle/vundle/ | |
call vundle#rc() | |
Bundle 'gmarik/vundle' | |
Bundle 'ctrlp' | |
filetype plugin indent on | |
" vundle config end |
This file contains hidden or 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
# TL;DR | |
puts method_find = [].method(:find) | |
# => #<Method: Array(Enumerable)#find> | |
if RUBY_VERSION =~ /^1.8/ | |
[method_find.__line__, method_find.__line__] | |
else | |
method_find.source_location | |
end |
NewerOlder