Skip to content

Instantly share code, notes, and snippets.

View samshull's full-sized avatar
🎯
Focusing

Sam Shull samshull

🎯
Focusing
View GitHub Profile
<!doctype html>
<html>
<head>
<style>
* { margin: 0; padding: 0; }
html, body { height: 100%; min-height: 100%; min-width: 100%; }
#expanding-width-background { width: 100%; height: 100%; position: absolute; top: 0; z-index: 1; background: red; }
#fixed-width { width: 500px; height: 100%; position: relative; z-index: 2; margin: 0 auto; background: blue; }
</style>
</head>
array(54) {
[1]=>
array(8) {
[0]=>
string(1) "9"
[1]=>
string(2) "11"
[2]=>
string(2) "26"
[3]=>
Sent through our site
:"ad-d_upgrade"=>"none",
:agent_id_number=>56061394,
:beneficiary=>"Joe Someone",
:cbTerms=>"true",
:cc_city=>"Fort Wayne",
:cc_cvv=>"xxx",
:cc_month=>"January",
:cc_number=>"xxxxxxxxxxxxxxxx",
:cc_postalcode=>"46802",
BenefitTemplate.where(:benefit_id => TERRORISM_ID).each { |bt| bt.update_attributes! :calculator_class => 'Terrorism' }
BenefitTemplate.where(:benefit_id => EMPLOYMENT_LAYOFF_ID).each { |bt| bt.update_attributes! :calculator_class => 'EmploymentLayoff' }
BenefitTemplate.where(:benefit_id => MEDICAL_EVACUATION_ID).each { |bt| bt.update_attributes! :calculator_class => 'MedicalEvacuationAndRepatriation' }
BenefitTemplate.where(:benefit_id => CANCEL_FOR_WORK_REASONS_ID).each { |bt| bt.update_attributes! :calculator_class => 'CancelForWorkReasons' }
BenefitTemplate.where(:benefit_id => HOME_COUNTRY_ID).each { |bt| bt.update_attributes! :calculator_class => 'HomeCountryCoverage' }
BenefitTemplate.where(:benefit_id => FINANCIAL_DEFAULT_ID).each { |bt| bt.update_attributes! :calculator_class => 'FinancialDefault' }
BenefitTemplate.where(:benefit_id => TERRORISM_ID).each { |bt| bt.update_attributes! :calculator_class => 'Terrorism' }
BenefitTemplate.where(:benefit_id => EMPLOYMENT_LAYOFF_ID).each { |bt| bt.update_attributes! :calculator_class => 'EmploymentLayoff' }
BenefitTemplate.where(:benefit_id => MEDICAL_EVACUATION_ID).each { |bt| bt.update_attributes! :calculator_class => 'MedicalEvacuationAndRepatriation' }
BenefitTemplate.where(:benefit_id => CANCEL_FOR_WORK_REASONS_ID).each { |bt| bt.update_attributes! :calculator_class => 'CancelForWorkReasons' }
BenefitTemplate.where(:benefit_id => HOME_COUNTRY_ID).each { |bt| bt.update_attributes! :calculator_class => 'HomeCountryCoverage' }
BenefitTemplate.where(:benefit_id => FINANCIAL_DEFAULT_ID).each { |bt| bt.update_attributes! :calculator_class => 'FinancialDefault' }
BenefitTemplate.find(134).update_attributes! :calculator_class => 'FinancialDefaultAfterWait'
BenefitTemplate.find(135).update_attributes! :calculator_class => '
diff --git a/src/node-proxy.cc b/src/node-proxy.cc
index 545ce0c..34ade71 100644
--- a/src/node-proxy.cc
+++ b/src/node-proxy.cc
@@ -266,7 +266,7 @@ Handle<Value> NodeProxy::Create(const Arguments& args) {
instance->SetPrototype(args[1]);
}
- return scope.Close(instance);
+ return instance;
# Ensures that the default shell is the same as the value of the $SHELL env variable
shell -$SHELL
# Define the time that all windows monitored for silence should
# wait before displaying a message. Default 30 seconds.
silencewait 15
# Automatically detach on hangup.
autodetach on
@samshull
samshull / gist:1169764
Created August 25, 2011 01:36 — forked from tjh/gist:1051092
Watchr script for Cucumber, Rspec, and Evergreen
system('clear')
ENV["WATCHR"] = "1"
$spec_cmd = "rspec --colour --format nested -d"
$evergreen_cmd = "evergreen run ."
GROWL = `which growlnotify`.chomp
if GROWL.empty?
puts "Missing growlnotify command for growl notifications"
if (!('filter' in Array.prototype)) {
// conforms with the ECMA standard
Array.prototype.filter = function filter(fn, thisArg) {
var index = 0, length = this.length, value, returnValue = [], that = Object(this);
for (; index < length; ++index) {
if (index in that) {
value = that[index];
if (fn.call(thisArg, value, index, that)) {
returnValue.push(value);
}
@samshull
samshull / gist:1139560
Created August 11, 2011 12:49
better_world
def better_world
people_of_the_world.reject! do |person|
person.is_lawyer? || person.is_politician?
end
end