Posted By

jlaplante on 04/22/10


Tagged

rake tasks


Versions (?)

Rake Tasks


 / Published in: Ruby
 

URL: http://blog.nanorails.com/pages/rails-1-1-cheat-sheet

  1. rake db:fixtures:load # Load fixtures into the current environment’s database.
  2. # Load specific fixtures using FIXTURES=x,y
  3. rake db:migrate # Migrate the database through scripts in db/migrate. Target
  4. # specific version with VERSION=x
  5. rake db:schema:dump # Create a db/schema.rb file that can be portably used against
  6. # any DB supported by AR
  7. rake db:schema:load # Load a schema.rb file into the database
  8. rake db:sessions:clear # Clear the sessions table
  9. rake db:sessions:create # Creates a sessions table for use with
  10. # CGI::Session::ActiveRecordStore
  11. rake db:structure:dump # Dump the database structure to a SQL file
  12. rake db:test:clone # Recreate the test database from the current environment’s
  13. # database schema
  14. rake db:test:clone_structure # Recreate the test databases from the development structure
  15. rake db:test:prepare # Prepare the test database and load the schema
  16. rake db:test:purge # Empty the test database
  17.  
  18. rake doc:app # Build the app HTML Files
  19. rake doc:clobber_app # Remove rdoc products
  20. rake doc:clobber_plugins # Remove plugin documentation
  21. rake doc:clobber_rails # Remove rdoc products
  22. rake doc:plugins # Generate documation for all installed plugins
  23. rake doc:rails # Build the rails HTML Files
  24. rake doc:reapp # Force a rebuild of the RDOC files
  25. rake doc:rerails # Force a rebuild of the RDOC files
  26.  
  27. rake log:clear # Truncates all *.log files in log/ to zero bytes
  28.  
  29. rake rails:freeze:edge # Lock this application to latest Edge Rails. Lock a specific
  30. # revision with REVISION=X
  31. rake rails:freeze:gems # Lock this application to the current gems (by unpacking them
  32. # into vendor/rails)
  33. rake rails:unfreeze # Unlock this application from freeze of gems or edge and return
  34. # to a fluid use of system gems
  35. rake rails:update # Update both scripts and public/javascripts from Rails
  36. rake rails:update:javascripts # Update your javascripts from your current rails install
  37. rake rails:update:scripts # Add new scripts to the application script/ directory
  38.  
  39. rake stats # Report code statistics (KLOCs, etc) from the application
  40.  
  41. rake test # Test all units and functionals
  42. rake test:functionals # Run tests for functionalsdb:test:prepare
  43. rake test:integration # Run tests for integrationdb:test:prepare
  44. rake test:plugins # Run tests for pluginsenvironment
  45. rake test:recent # Run tests for recentdb:test:prepare
  46. rake test:uncommitted # Run tests for uncommitteddb:test:prepare
  47. rake test:units # Run tests for unitsdb:test:prepare
  48.  
  49. rake tmp:cache:clear # Clears all files and directories in tmp/cache
  50. rake tmp:clear # Clear session, cache, and socket files from tmp/
  51. rake tmp:create # Creates tmp directories for sessions, cache, and sockets
  52. rake tmp:sessions:clear # Clears all files in tmp/sessions
  53. rake tmp:sockets:clear # Clears all ruby_sess.* files in tmp/sessions

Report this snippet  

You need to login to post a comment.