RubyKaigi2009 åæ¥ã¡ã¢
æãè¿ãã° DHH ãæå¾ è¬æ¼ãã¦ãã 2006 å¹´ã® Rubyä¼è°ããä»å¹´ã§ 4åç®ãä½æ°ã«èªåãå ¨é¨åå ãã¦ãããã¨ã«ã³ã£ãããã¾ããã (^^;
ä»å¹´ã®ãã¼ãã¯ãå¤ãã/å¤ããããããã¦è£ãã¼ãã¯ãCOBOLã?ã
ä¸éå½éè²è±ããªã®ãä»å¹´ã®ç¹å¾´ã§ãããä¸çå°å³ã«åºèº«ãä»ç®ç´ã§è²¼ã£ã¦ãã®ã¯é¢ç½ãã¢ã¤ãã¢ã§ããã
åä»æ¸ã¾ãã¦çµ¦é»æã§ã¼ã¼ã£ã¨ãã¦ããè§è°·ããã«ä¼ã£ã¦ãä¼å ´åã®éè·¯ã RubyConf 風ã«ãã¦ã¿ãã¨è¨ã£ã¦ã¾ããããããã«é£çµ¡ãã¼ãã¨ãããªã³ã¯ãµã¼ãã¹ã給é»æãªãããããã®ã¯ä¼¼ã¦ãããã
å
¨ä½çãªå
容ãé°å²æ°ã«ã¤ãã¦ã¯ãã§ã« gihyo.jp ããã¨ãã§å
¬éããã¦ã (GJ!) ã®ã§ã以ä¸ã¯èªåç¨ã®ã¡ã¢ã
git
- çºè¡¨è
ã® Scott Chacon ãããæ¬ãæ¸ããããã
- CC ã©ã¤ã»ã³ã¹ã§ããããå ¬é (ç´ æ´ããã)
- http://progit.org/
- git rebase --onto
- branchã®branchãmasterã«å½ã¦ããããéä¸ã®serverãã©ã³ãã®é¨åããããªã
- git rebase serverã ãããã¨ãã ã
- --ontoã使ãã¨ãserverããã¿ãclientãã©ã³ãã®ã³ããããã¨ã£ã¦ãmasterã«å½ã¦ã
- squash
- squashããã°ãè¤æ°ã³ããããä¸ã¤ã«ãªã
- pickãã¦ãsquashããããæ°ããã³ãããã¡ãã»ã¼ã¸ãä»ãã
- 注æï¼ãã¼ã«ã«ã®ã³ãããã§ãããpushãããã®ã«å¯¾ãã¦ãããª
- Fork QUeue
- ä»ã®forkã§ã®ã³ããããããããã«ã¿ãã
- ç·ã¯åé¡ãªãã¨ãããããã®ã赤ã®å ´åã¯è¡çªããã
- rebase 㨠merge ã®ä½¿ãåã
- ãã¼ã«ã«ã ãã§ç®¡çã®ã¨ã or å¤ããåãè¾¼ãã¨ããããã§ä½¿ãåã
ç¾å ´ã§å½¹ç«ã¤ RoR ãã¿ã¼ã³
- è¨è¨ / å®è£
ã®ä¸ä½åã§èªåãå®è£
ã§ãããã¨ããæå³ã§ã¨ã³ã¿ã¼ãã©ã¤ãºã§ã RoR ãæ´»ç¨
- ããã¼ã¸ã¡ã³ãããªãã·ã§ã¢ãªã©ãå®è£ ã§ããªãæµãã¯å«
- 課é¡
- æ¸ãæ¹ãã°ãã°ã
- å質ãæã£ã¦ããªãã®ã§ãã¡ã³ããã³ã¹ãã«ãããªã
- ã³ã¼ããããç¶æ
ã«ä¿ã¤ã«ã¯ï¼
- å ±éãã¿ã¼ã³
- DSL (æ§ãç®ã«å©ç¨ãããããã¯æ°è¦åå ¥è ã®éå£)
- 権éã®ãããã¼ã¿ã®è¡¨ç¤º
- find_by_user_id ã named scope ã§ããã°ãã®ã¯æ¡ä»¶ãæ¸ãå¿ãã¦ãæ°ã¥ãã«ãã
- é¢é£ã使ã£ã¦ããªãã¸ã§ã¯ãããã¯ãããæ¤ç´¢ããã
@note = current_user.notes.find(params[:id]
-
- ãã¼ã¿ã®æ¨©å©è ãã¿ã¼ã³
- Filter ã®å©ç¨
- éè¤ãã¦ããå¦çã Filter ã«åãåºã
- ããç¨åº¦å¼·å¶åãåã..ã®ããªï¼
- è¤éãªãã¸ãã¹ãã¸ãã¯ã®ã¢ãã«ã¸ã®éãæ¹
- Model ã®ãªãã« do_createãdo_destroy ã¡ã½ãããåã£ãã²ã¨ããã (ã³ã£ãã!)
- ã³ã³ããã¼ã©ã«æ¸ããã¡ãªå¦çãã¢ãã«ã«ãã£ã¦ãã
- ã¢ãã«ã§ attr_accessor 㧠DB ã«é¢ä¿ãªãå±æ§ã追å
- ãã©ã¡ã¼ã¿æ§é ãããã # form_for ã使ãã¨ã
- ããã§ãã©ã¡ã¼ã¿ãåãã¨ã£ãã¿ã¤ãã³ã°ã§ã¢ãã«ã«ã¯ããã®ã§ã³ã³ããã¼ã©ã§åå²å¦çãæ¸ãå¿ è¦ããªããªã
- ä»éããä»ã¢ãã«ã¸ã®å¦çã®ç§»å
- ããã¢ãã«ã触ãã¤ãã§ã«å¥ã¢ãã«ããããå ´åãã³ã³ããã¼ã©ã«ããããã¡
- ã¢ãã«ã®ã³ã¼ã«ãã㯠(save ã destroy ãªã©ã®åå¾ã«å¼ã³åºãããå¦ç) ã«ç§»ãã¾ããã
- 話ããªãã£ããã¨
- å¤ã¬ãã«ã®æ¤è¨¼ (ç¯å²ã決ãã¦æ¤è¨¼ã¨ã) # ããèããããª
- STI ã®åå
- é¢é£ãªãã¸ã§ã¯ãã«å±æ§æ å ±ãä¼ãã
- routes.rb ã®æ´ç
- å®è£
ãã¿ã¼ã³ã®è¦ãã ãæ¹
- 誰ã®ãã¹ãä»äºãªã®ãã«ãã ãã
- ååã«å¾ã (DRYãCoCãRESTful)
- ã³ã³ããã¼ã©ã®è¨è¨ã¯ãURL è¨è¨ãã (対象ãªã½ã¼ã¹1種é¡ã«ã¤ã 1ã³ã³ããã¼ã©)
- è¤æ°ãªã½ã¼ã¹ã® CRUD ãã²ã¨ã¤ã®ã³ã³ããã¼ã©ã«ã¯ãã£ã¦ããã®ã¯ã¾ãã
- ãã¤ãã
- Q. æ³å®ãã¦ããéçºè æ°
- A. 10人以ä¸ã4-5ã¶æã®éçºæé
- Q. æ°ã¥ãã¨ã¢ãã«ã1000è¡ã¨ã...ãããã£ãå ´åã¯ï¼ by é£ã¹ããã®äº¬åãã
- A. æ©è½å¥ã«ã¢ã¸ã¥ã¼ã«ã«åãåºãã1ãã¡ã¤ã«ã®å 容ããã¼ã
- Q. ã¢ã¸ã¥ã¼ã«ãå¢ãã¦ãåå空éã«ãã¾ã£ããããªãï¼
- A. ã¢ãã«ã«ãã£ãååãã¤ããã¨ã
- ãã¨ã§å¤§å ´ããã«èããããã¾ããã³ã¼ãã®æ¤ç¥ã¯ãã¢ããã ãããª
ãã¨ã³ã¿ã¼ãã©ã¤ãº Railsã ã«å¦ã¶ä¼æ¥ã®ããã® Rails ã¢ã¼ããã¯ãã£
- ããªãã®ä¼ç¤¾ã§ãã¡ã°ã大åãªè³ç£ã£ã¦ä½ã§ããï¼
- 人æï¼
- ã¨ã³ã¿ã¼ãã©ã¤ãºãªã²ã¨ã«ã¨ã£ã¦ã¯ãè¦å¡ããããã»ã©éè¦ãããªãw
- ããã¯ãã¼ã¿ã§ãã
- ãã¼ã¿ä¸å¿ã¢ããã¼ã
- ããã»ã¹ããããã¼ã¿ã®ã»ããå®å®ç
- è¦æ±ããã¼ã¿ã«å¯¾ãããã®ã¨ãã¦ä½ç³»åã§ãã
- ãã¼ã¿ã¢ãã«ã«ãã£ã¦æ¥åã«ã¼ã«ãåæã§ãã
- Rails 㨠DOA ã®é¡ä¼¼ç¹
- RDBMS ãåæã«ããã¢ã¼ããã¯ãã£
- ã¢ãã«ä¸å¿ã®ãã¬ã¼ã ã¯ã¼ã
- ã¢ãã«ã«å¯¾ãã CRUD åæãéè¦ãã
- Rails 㨠DOA ã®ç¸éç¹
- ãã¼ã¿ã¢ãã«ãéè¦ããªã # ã¢ã¸ã£ã¤ã«ãªããæ¹
- æ¥åã«ã¼ã«ã¯ã¢ããªå±¤ã®ã¿ã§å®ç¾
- èæ¯ã«ã¯ããªã½ã¼ã¹æåã¢ã¼ããã¯ã㣠(ROA)
- DOA 㨠Rails ã®ã®ã£ãããåããã®ããã¨ã³ã¿ã¼ãã©ã¤ãº Railsã
- ããã¾ã§åããª
- ãã¼ã¿ãä¿è·ããããã«ã¯ãã¢ããªå±¤ã ããããªããDB層ã®å¶ç´ã使ã
- NOT NULL å¶ç´
- ãã§ãã¯å¶ç´ # 4æå以ä¸ã¨ã (ãããªã®ãã£ãã®ã)
- ãã¼ã¿ãã¼ã¹ã®ã¦ããããã¹ã
- save_with_validation(false) ã¨ãããã¨ãmodell ã® validation ãã¯ããã¦DBã®ãã§ãã¯ã確èªã§ãã
- å¤é¨ãã¼
- ãã¼ã¿ãã¼ã¹ã§ã¡ããã¨ãã§ãã¯ããããã«ã¯è¤å主ãã¼ã®ã»ããé½åããã
- Rails ã§ã®è¤å主ãã¼ã¸ã®å¯¾å¿ãcomposit_primary_key
set_primary_keys
has_many :foreign_keys => [...]
- ãã¼ã¿ãã¼ã¹ãã¥ã¼ã®å©ç¨
- View-backed ã¢ãã«
- migration ã§ã¯ãexecute ã使ã
Rails3
- ççµåå
- ActiveRecordãActiveControllerãActiveView ããã£ããå¯ã«çµå
- Rails3 ã§ã¯ãã®ãããã綺éºã«æé¤
- Railså é¨ã ActiveSupport ã®å¿ è¦ãªã¨ããã ãã requireãã¡ããã¨ä¾åé¢ä¿ãå°é
- Railsæ¬ä½ã®ããã©ã¯ãã¶ãallãrequireãããã©(便å©ã ãã)ããªãã«ãããªãã·ã§ã³ã¯ãã
- ãã ããããããã¯requireé ãéè¦ã«ãªã
- ããã楽ã«ããã®ã«ãActiveSuppor::Concern ã追å ãã
- includedã¨ããã¡ã½ããã§ã¢ã¸ã¥ã¼ã«ããã§ã«ãã¼ãããã¦ããããç°¡åã«ç¢ºèªã§ãã
- depends_on ã§ä¾åé¢ä¿ãæ確ã«ãããã¨ãã§ããï¼
- Rails 㯠Ruby Citizen ã«ãªã
Lightning Talks
- wiki ãã¿ã¼ã³ã©ã³ã²ã¼ã¸
- Ruby/Tk
- Rails on GAEJ
- IronRuby on Rails
- Silverline
- peeled unshiu
- CGM ãã¬ã¼ã ã¯ã¼ã¯ # F/W ä½æã® F/Wï¼
- wakame
- ã»ããã¢ããã®èªåå
- gem install wakame
- ã³ãã³ã㧠Rails ã¤ã³ã¹ã¿ã³ã¹ãå¢ãããããMySQL ã®ã¬ããªã±ã¼ã·ã§ã³ãå¢ãããã
- Amazon EC2 ãã¼ã¹
- JCL
- arabesque
- Miyazaki Resistance
- AR ã®ããã« TT (TC) ã使ãã
- TT ã® API ã®æªãã解æ¶
- KVS
- Entity 㨠Presentation 層㫠Excel ãå©ç¨
- ãã¸ãã¹ãã¼ã½ã³ã使ãã KVS
- XLS_KVS
- lang-8
- Rails ã®ããã«ãã㯠=> RDB
- MySQL 㧠2msec ãã¯ã©ã¦ãDB ã 㨠20msec
- ã¯ã¨ãªãã²ããããã£ãã·ã¥ãããããªãï¼
æ親ä¼
- iPhone 人å£å¤ããBamp ãããªã¼