Add gems:
bundle add lefthook
bundle add standard
bundle add standard-rails
Setup standard-rails (optional, often requires a lot of changes):
Add the provided .standard.yml
file.
Install Left Hook:
lefthook install
Copy/paste the .lefthook.yml
file.
Install again to update the hooks
lefthook install
Commits, pushes and merges should now check if clean, it'll also run standardrb --fix before
Commit to verify things are working:
git add -A && git commit -m "Have some standards! Add lefthook and standard"