Code snippets for rails workflow