DEV Community

Discussion on: "Crap, I broke production" - How do we ensure it never happens again?

Collapse
 
nijeesh4all profile image
Nijeesh Joshy • Edited

I did something similar once, i pushed the code without removing binding.pry ( its like debugger for Ruby ). and i found about after deploying to staging ( good thing that we didn't pushed to production directly).

Learned about git precommit hooks that day. and i haven't done that mistake since. and have been telling juniors about it.

i think its important that we make mistakes, so other's doesn't have to make the same mistake.

"The only real mistake is the one from which we learn nothing."

Collapse
 
miniscruff profile image
miniscruff

I am not a Ruby Dev but it sounds like that file should be git ignored

Collapse
 
nijeesh4all profile image
Nijeesh Joshy

It's not a file, but it's just a single line of debugger statement used for setting breakpoint for your code execution.