Skip to content

Instantly share code, notes, and snippets.

View trak3r's full-sized avatar

Thomas "Teflon Ted" Davis trak3r

View GitHub Profile
http://www.esurance.com/car-insurance-info/teen-driver-insurance-faq#ch7
"... in most cases, your policy will protect your young driver until he or she
is licensed."
http://www.carinsurancecomparison.com/if-your-child-gets-a-learners-permit-do-yo
u-have-to-add-them-to-your-auto-insurance-policy/
"... as long as the adult driver who owns the car is covered the child will be
too. However, some companies require notification."
this is a test of gist from vim.
this gist was edited by a fresh vim copy.
call unite#filters#matcher_default#use(['matcher_fuzzy'])
call unite#custom#source('buffer,file,file_rec/git','sorters', 'sorter_selecta')
nnoremap <leader>t :<C-u>Unite -no-split -buffer-name=files -profile-name=buffer -start-insert file_rec/git<CR>
call unite#custom#profile('buffer', 'ignorecase', 1)
This is what i see in my unite buffer:
28 a app/assets/javascripts/backbone/comp..ews.js.coffee [coffee] (2014/06/09 16:10:54)
27 %a app/assets/javascripts/backbone/comp..ler.js.coffee [coffee] (2014/06/09 16:57:00)
The file names are so grossly truncated as to be useless.
1. Can I truncate the path prefixes instead of the file names? If so, how?
2. Can I kill the file type and time stamp columns? If so, how?
The old prototype machine had our AWS API access key and secret key. Once the
hacker gained access to the keys, he created an IAM user, and generated a
key-pair. He was then able to run an instance inside our AWS account using
these credentials, and mount one of our backup disks. This backup was of one of
our component services, used for production environment, and contained a config
file with our database password. He also whitelisted his IP on our database
security group, which is the AWS firewall.
module Delayed
class Worker
class << self
def sleep_delay_with_fudging
# stagger sleeps by +/- 10% so all the workers don't spike at same time
sleep_delay_without_fudging * rand(0.9..1.1)
end
alias_method_chain :sleep_delay, :fudging
end
end
Dear Git experts,
The other day I had made a change to my code and committed it then realized I was in an unrelated branch; I had intended to commit the change to master.
I switched to master and attempted to merge just the errant commit (by the long hash key) from the branch but that ended up merging the entire branch into master.
I blame this faux pas on my still-ingrained Subversion mentality.
Where did I go wrong? How should I have handled correcting the mistake?
$ port list | grep ruby
ruby @1.8.7-p72 lang/ruby
$ sudo port install ruby @1.8.7-p72
---> Installing ruby @1.8.6-p114_0+darwin_9+thread_hooks
WTF!?
= link_to_remote(image_tag(video.thumbnail_url, :alt => h(video.title)), :update => 'main', :url => { :action => 'wtf', :id => video.id })
# produces "/videos/wtf/77"
= link_to_remote(image_tag(video.thumbnail_url, :alt => h(video.title)), :update => 'main', :url => { :action => 'show', :id => video.id })
# produces "/videos/77"
# notice how it *removed* the 'show' action from the url!?
# 1) Point *.example.com in your DNS setup to your server.
#
# 2) Setup an Apache vhost to catch the star pointer:
#
# <VirtualHost *:80>
# ServerName *.example.com
# </VirtualHost>
#
# 3) Set the current account from the subdomain
class ApplicationController < ActionController::Base