Skip to content

Instantly share code, notes, and snippets.

@cw4d3
cw4d3 / gist:1468504
Created December 12, 2011 18:40
MM3-ProxySwitcher Config
[Burp Suite - 8001
http=127.0.0.1:8001
ftp=127.0.0.1:8001
ssl=127.0.0.1:8001
noProxy=127.0.0.1:8001
clear=cache
]
[WebScarab - 8002
http=127.0.0.1:8002
ftp=127.0.0.1:8002
@cw4d3
cw4d3 / broken 'rake'
Created February 22, 2011 02:14
my rake is broken!
:~/Desktop/grigio-rails3-ujs-demo-eb6cb9b :: rake db:migrate
/usr/local/lib/ruby/site_ruby/1.9.1/rubygems.rb:370:in `bin_path': can't find gem rake ([">= 0"]) with executable rake (Gem::GemNotFoundException)
from /usr/local/bin/rake:19:in `<main>'
:~/Desktop/grigio-rails3-ujs-demo-eb6cb9b :: which rake
/usr/local/bin/rake
#Listed as a LOCAL GEM: rake (0.8.7)
#########################################
@cw4d3
cw4d3 / pushing to numerous remote repos
Created February 15, 2011 05:54
pushing to numerous remote repos via .git/config
#update .git/config to something similar to this.
#from:
#stackoverflow: http://stackoverflow.com/questions/165092/can-i-#push-to-more-than-one-repository-in-a-single-command-in-#git
You can have several URLs per remote in git, even though the git remote command did not appear to expose this last I checked. In .git/config, put something like this:
[remote "public"]
url = git@github.com:kch/inheritable_templates.git
url = kch@homeserver:projects/inheritable_templates.git
Now you can say “git push public” to push to both repos at once.
@cw4d3
cw4d3 / about_exceptions_1.rb
Created January 31, 2011 01:59
from test_about_exceptions.rb Koan
class AboutExceptions
class MySpecialError < RuntimeError
end
def test_rescue_clause
result = nil
begin
fail "Oops"
rescue StandardError => ex