Skip to content

Instantly share code, notes, and snippets.

@wikimatze
Forked from nesquena/my_template.rb
Last active May 10, 2018 19:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wikimatze/b6162d50612e7ccabf3ee806dbaa5767 to your computer and use it in GitHub Desktop.
Save wikimatze/b6162d50612e7ccabf3ee806dbaa5767 to your computer and use it in GitHub Desktop.
project :test => :rspec, :orm => :activerecord
generate 'model', 'account username:string password:string'
generate 'model', 'post title:string body:text'
generate 'controller', 'posts get:index get:new post:new'
generate 'controller', 'users get:index'
generate 'migration', 'AddEmailToAccount email:string'
require_dependencies 'nokogiri'
git :init
git :add, "."
git :commit, "-m 'initial commit'"
inject_into_file 'app/models/post.rb','#Hello', :after => "end\n"
rake 'ar:create ar:migrate'
initializer :test, '# Example'
git :add, '.'
git :commit, "- m 'second commit'"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment