Skip to content
Browse files

add pre-commit

  • Loading branch information...
1 parent 73f5988 commit 9ceea2faca9c105a74668eff27dc49e67f0e2528 @naoty committed Jun 22, 2012
Showing with 8 additions and 0 deletions.
  1. +8 −0 pre-commit
View
8 pre-commit
@@ -0,0 +1,8 @@
+#!/usr/bin/env ruby
+
+# check binding.pry
+cached_files = `git diff --cached --name-only`
+if cached_files.split($/).all? { |path| File.read(path).include?('binding.pry') }
+ puts 'WARNING: binding.pry is found.'
+ exit 1
+end

0 comments on commit 9ceea2f

Please sign in to comment.
Something went wrong with that request. Please try again.