Skip to content

Instantly share code, notes, and snippets.

View cibernox's full-sized avatar
🏠
Working from home

Miguel Camba cibernox

🏠
Working from home
View GitHub Profile
@bestie
bestie / pre-commit
Created September 16, 2011 20:28
Rails Git pre-commit hook for ensuring schema.rb and migration changes commit atomically
#!/usr/bin/env ruby
# vim: set syntax=ruby
# Ensures that changes to the Rails schema.rb file may only be committed if a
# migration file is also committed at the same time.
def schema_modified?
%x[ git diff --cached |grep schema.rb ] == ''
end
@pellejacobs
pellejacobs / binding.pry.sublime-snippet
Created October 3, 2015 23:29
binding.pry for pry debugging
<snippet>
<content><![CDATA[
binding.pry
]]></content>
<tabTrigger>binding</tabTrigger>
<description>binding.pry</description>
<scope>source.ruby</scope>
</snippet>