Skip to content

Instantly share code, notes, and snippets.

url = %r{
^
([A-Za-z]*) # scheme (e.g. http)
:
(?:
// # mailto: and news: URLs do not require forward slashes
)?
([0-9.\-A-Za-z@]*) # domain (e.g., www.regexml.org)
vlc --audio-filter=param_eq --param-eq-f1=233 --param-eq-f2=466
--param-eq-f3=932 --param-eq-gain1=-20 --param-eq-gain2=-20
--param-eq-gain3=-20 --param-eq-lowf=100 --param-eq-lowgain=15
--param-eq-q1=10 --param-eq-q2=10 --param-eq-q3=10
diff --git a/lib/phusion_passenger/utils.rb b/lib/phusion_passenger/utils.rb
index e9bc00e..792cc46 100644
--- a/lib/phusion_passenger/utils.rb
+++ b/lib/phusion_passenger/utils.rb
@@ -226,6 +226,18 @@ protected
ENV["RACK_BASE_URI"] = base_uri
end
+ # load project specific rvm settings
+ if ENV['MY_RUBY_HOME'] && ENV['MY_RUBY_HOME'].include?('rvm') && File.exists?(".rvmrc")
# git lye
# An attempt to make rebasing easy, by draining unnessarcy commit noise.
# No warranty, use at own risk.
# Author Hannes Tydén <[email protected]>
# Contributor Tobias Schmidt <[email protected]>
# TODO
# - Don't sign off all commits are by current user.
@grobie
grobie / install_ruby_patch.sh
Created May 31, 2011 16:00
Install ruby-head (1.9.3) and patch `require`
# Install ruby-head (1.9.3) and patch `require`
#
# using: rvm and homebrew
# update dependencies
brew install libyaml readline
# update rvm
rvm get head
rvm reload
@grobie
grobie / gist:1040325
Created June 22, 2011 15:20
google code issue template
What steps will reproduce the problem?
1.
2.
3.
What is the expected output? What do you see instead?
What version of Sequel Pro are you using? What version of MySQL are you
connecting to on the server?
<!DOCTYPE html>
<!--[if IE]>
<![endif]-->
<html><head><meta charset="utf-8" />
<title>Flickermood by Forss on SoundCloud - Create, record and share your sounds for free</title>
<meta content="record, sounds, share, sound, audio, tracks, music, soundcloud" name="keywords" />
<meta content="Listen to Flickermood by Forss: From the Soulhack album,&amp;nbsp;recently featured in this ad &lt;a href=&quot;https://www.dswshoes.com/tv_commercial.jsp?m=october2007&quot;&gt;https://www... | Create, record and share the sounds you create anywhere to friends, family and the world with SoundCloud, the world's largest community of sound creators." name="description" />
<meta content="width=device-width" name="viewport" />
<meta content="chrome=1" name="X-UA-Compatible" />
Read only mode
--------------
- Write tests
- Clock.parse
- connection_error (integration test)
- integration tests
- with_consistency accepts string clock
- raise MasterUnavailable in all cases
- connection stack usage
class MyController
validate :username => String,
:permalink => String,
:user => {
:age => Fixnum,
:numbers => Array
}
:on => :update
def update
#!/usr/bin/env ruby
require 'ipaddr'
# Creates a regexp of trusted IP addresses to be used by Rails'
# ActionController::Request::TRUSTED_PROXIES.
#
class TrustedProxyRegexpCreator
OCTET = '\d{1,3}'
EDGECAST_IP_FORMAT = /#{OCTET}\.#{OCTET}\.#{OCTET}\.(\*|#{OCTET})/