Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

はじめてのSymfony2

6,012 views

Published on

CLIについて

Published in: Technology
  • Be the first to comment

はじめてのSymfony2

  1. 1. Symfony2 Tomohiro Mitsumune
  2. 2. • Tomohiro Mitsumune (a.k.a. Kiske)•• Jobeet • http://d.hatena.ne.jp/Kiske/
  3. 3. Symfony
  4. 4. CLI
  5. 5. php app/console xxxxx
  6. 6. init:bundle•• • • appKernel, autoload
  7. 7. Google
  8. 8. Symfony2Project• https://github.com/Garfield-fr/ Symfony2Project• CLI
  9. 9. php symfony2project generate:projectBlog Company blog--controller="Blog" --session-start--session-name="blog"--orm="doctrine" --assetic--swiftmailer --doctrine-migration--doctrine-fixtures
  10. 10. Symfony2Project• • beta2 Doctrine Common 3.0 github master 2.0.x$ cd vender/doctrine-common$ git branch -av$ git checkout -b 3.0.x origin/3.0.x
  11. 11. assets:install• asset• asset • src/Acme/DemoBundle/Resource/public/
  12. 12. router:debug••
  13. 13. router:dump-apache• mod_rewrite•
  14. 14. doctrine:database• doctrine:database:create • config.yml database create• doctrine:database:drop • • --force drop
  15. 15. doctrine:generate:entity• Entity•• • Entity • Mapping use • mapping-type yml
  16. 16. php app/consoledoctrine:generate:entityAcmeDemoBundle:User“name:string(255) email:string(255)createdAt:datetime”
  17. 17. doctrine:generate:entities• Entity • setter/getter • repository• • entity entities
  18. 18. doctrine:schema• doctrine:schema:create • Entity DB• doctrine:schema:drop • Entity drop• doctrine:schema:update • Entity DB
  19. 19. CLI
  20. 20. Symfony2

×