ruby 1.8.6 ÃüÁî_Ruby_±à³Ì¿ª·¢_³ÌÐòÔ±¾ãÀÖ²¿

ÖйúÓÅÐãµÄ³ÌÐòÔ±ÍøÕ¾³ÌÐòԱƵµÀCXYCLUB¼¼ÊõµØͼ
ÈÈËÑ£º
¸ü¶à>>
 
ÄúËùÔÚµÄλÖ㺠³ÌÐòÔ±¾ãÀÖ²¿ > ±à³Ì¿ª·¢ > Ruby > ruby 1.8.6 ÃüÁî

ruby 1.8.6 ÃüÁî

 2012/4/18 23:20:29  chen_miao  ³ÌÐòÔ±¾ãÀÖ²¿  ÎÒÒªÆÀÂÛ(0)
  • ÕªÒª£º1.1´´½¨Ò»¸öRailsÓ¦ÓóÌÐò$railsapp_name¿ÉÑ¡Ïî:-d,database=xxxÖ¸¶¨°²×°Ò»¸öÊý¾Ý¿â(mysqloraclepostgresqlsqlite2sqlite3),ĬÈÏÇé¿öÏÂÊÇÊý¾Ý¿â-r,ruby-path=Ö¸¶¨RubyµÄ°²×°Â·¾¶,Èç¹ûûÓÐÖ¸¶¨£¬scriptsʹÓÃenvÈ¥ÕÒRuby-f,freeze(¶³½á)freezesRailsÔÚvendor/railsĿ¼1.2APIDocumentation$gem_serverÆô¶¯Ò»¸öWEBrick·þÎñÆ÷
  • ±êÇ©£ºRuby ÃüÁî

1.1 ´´½¨Ò»¸öRailsÓ¦ÓóÌÐò
?$ rails app_name
?¿ÉÑ¡Ïî:
?-d, database=xxx Ö¸¶¨°²×°Ò»¸öÊý¾Ý¿â(mysql oracle postgresql sqlite2 sqlite3 ), ĬÈÏÇé¿öÏÂÊÇÊý¾Ý¿â
?-r, ruby-path= Ö¸¶¨RubyµÄ°²×°Â·¾¶,Èç¹ûûÓÐÖ¸¶¨£¬scriptsʹÓÃenvÈ¥ÕÒRuby
?-f, freeze (¶³½á)freezes RailsÔÚvendor/railsĿ¼
?
1.2 API Documentation
?$ gem_server
?Æô¶¯Ò»¸öWEBrick·þÎñÆ÷¡£ÕâʱºòÄã¿ÉÒÔͨ¹ýHttp://localhost:8808/ ´ò¿ªä¯ÀÀÆ÷È¥²é¿´rails APIÎĵµ
?
1.3 Rake
?rake db:fixtures:load
??# ÔØÈëfixturesµ½µ±Ç°»·¾³µÄÊý¾Ý¿â
??# ÔØÈëÖ¸¶¨µÄfixturesʹÓÃFIXTURES=x,y
?rake db:migrate
?# ǨÒÆÊý¾Ý¿âͨ¹ýÔÚdb/migrateĿ¼ÏµĽű¾.¿ÉÒÔÖ¸¶¨°æ±¾ºÅͨ¹ýVERSION=x
?rake db:schema:dump
?# ´´½¨Ò»¸ödb/schema.rbÎļþ£¬Í¨¹ýARÄܹý¹»Ö§³ÖÈκÎÊý¾Ý¿âȥʹÓÃ
?rake db:schema:load
?# ÔÙÈëÒ»¸öschema.rbÎļþ½øÊý¾Ý¿â
?rake db:sessions:clear
?# Çå¿Õsessions±í
?rake db:sessions:create
?# ÓÃCGI::Session::ActiveRecordStore´´½¨Ò»¸ösessions±íΪÓû§
?rake db:structure:dump
?# µ¼³öÊý¾Ý¿â½á¹¹ÎªÒ»¸öSQLÎļþ
?rake db:test:clone
?# ÖØд´½¨Ò»¸ö²âÊÔÊý¾Ý¿â´Óµ±Ç°»·¾³Êý¾Ý¿âÖÐ
?rake db:test:clone_structure
?# ÖØд´½¨²âÊÔÊý¾Ý¿â´Ó¿ª·¢Ä£Ê½Êý¾Ý¿â
?rake db:test:prepare
?# ×¼±¸²âÊÔÊý¾Ý¿â²¢ÔÚÈëschema
?rake db:test:purge
?# Çå¿Õ²âÊÔÊý¾Ý¿â
?rake doc:app
?# ´´½¨HTMLÎļþµÄAPI Documentation
?rake doc:clobber_app
?# ɾ³ýDocumentation
?rake doc:clobber_plugins
?# ɾ³ý plugin Documentation
?rake doc:clobber_rails
?# ɾ³ýDocumentation
?rake doc:plugins
?# ²úÉúDocumationΪËùÓа²×°µÄplugins
?rake doc:rails
?# ´´½¨HTMLÎļþµÄAPI Documentation
?rake doc:reapp
?# Ç¿ÖÆÖØд´½¨HTMLÎļþµÄAPI Documentation
?rake doc:rerails
?# Ç¿ÖÆÖØд´½¨HTMLÎļþµÄAPI Documentation
?rake log:clear
?# Çå¿ÕĿ¼log/ϵÄËùÓÐÈÕÖ¾Îļþ
?rake rails:freeze:edge
?# Lock this application to latest Edge Rails. Lock a specific revision with REVISION=X
?rake rails:freeze:gems
?# Lock this application to the current gems (by unpacking them into vendor/rails)
?rake rails:unfreeze
?# Unlock this application from freeze of gems or edge and return to a fluid use of system gems
?rake rails:update
?# Update both scripts and public/javascripts from Rails
?rake rails:update:javascripts
?# Update your javascripts from your current rails install
?rake rails:update:scripts
?# Add new scripts to the application script/ directory
?rake stats
?# Report code statistics (KLOCs, etc) from the application
?rake test
?# Test all units and functionals
?rake test:functionals
? # Run tests for functionalsdb:test:prepare
?rake test:integration
?# Run tests for integrationdb:test:prepare
?rake test:plugins
?# Run tests for pluginsenvironment
?rake test:recent
?# Run tests for recentdb:test:prepare
?rake test:uncommitted
?# Run tests for uncommitteddb:test:prepare
?rake test:units
?# Run tests for unitsdb:test:prepare
?rake tmp:cache:clear
?# Çå¿Õtmp/cacheĿ¼ÏµÄËùÓÐÎļþ
?rake tmp:clear
?# Çå¿Õsession, cache, ºÍsocketÎļþ´Ótmp/Ŀ¼
?rake tmp:create
?# Ϊsessions, cache, and sockets´´½¨tmp/Ŀ¼
?rake tmp:sessions:clear
?# Çå¿ÕËùÓÐÔÚtmp/sessionsĿ¼ÏµÄÎļþ
?rake tmp:sockets:clear
?# Çå¿ÕËùÓÐÔÚtmp/sessions Ŀ¼ÏµÄruby_sess.* Îļþ
?
1.4 Scripts
?script/about
?# Êä³öµ±Ç°»·¾³ÐÅÏ¢
?script/breakpointer
?# Æô¶¯¶Ïµãserver
?script/console
?#?Æô¶¯½»»»Ê½µÄRails¿ØÖÆ̨
?script/destroy
?# ɾ³ýͨ¹ýgenerators´´½¨µÄÎļþ
?script/generate
?# -> generators
?script/plugin
?# -> Plugins
?script/runner
?# Ö´ÐÐÒ»¸öÈÎÎñÔÚrailsÉÏÏÂÎÄÖÐ
?script/server
?# Æô¶¯¿ª·¢Ä£Ê½·þÎñÆ÷http://localhost:3000
?//ÒÔϼ¸¸ö²»ÖªµÀÔõôȥʹÓÃ
?script/performance/profiler
?script/performance/benchmarker
?script/process/reaper
?script/process/spawner
?
1.5 Generators
?ruby script/generate model ModelName
?ruby script/generate controller ListController show edit
?ruby script/generate scaffold ModelName ControllerName
?ruby script/generate migration AddNewTable
?ruby script/generate plugin PluginName
?ruby script/generate mailer Notification lost_password signup
?ruby script/generate web_service ServiceName api_one api_two
?ruby script/generate integration_test TestName
?ruby script/generate session_migration
?¿ÉÑ¡Ïî:
?-p, --pretend Run but do not make any changes.
?-f, --force Overwrite files that already exist.
?-s, --skip Skip files that already exist.
?-q, --quiet Suppress normal output.
?-t, --backtrace Debugging: show backtrace on errors.
?-h, --help Show this help message.
?-c, --svn Modify files with subversion. (Note: svn must be in path)?
?
1.6 Plugins
?script/plugin discover
?# discover plugin repositories
?script/plugin list
?# list all available plugins
?script/plugin install where
?# install the a€wherea€? plugin
?script/plugin install -x where
?# install where plugin as SVN external
?script/plugin install http://invisible.ch/projects/plugins/where
?script/plugin update
?# update installed plugins
?script/plugin source
?# add a source repository
?script/plugin unsource
?# removes a source repository
?script/plugin sources
?# lists source repositories

?

?

?

form:http://www.iteye.com/topic/43500

·¢±íÆÀÂÛ
Óû§Ãû: ÄäÃû