- Timestamp:
- 10/30/09 07:04:34 (4 years ago)
- Files:
-
- doc/branches/1.3/reference/en/16-Tasks.markdown (modified) (32 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
doc/branches/1.3/reference/en/16-Tasks.markdown
r22991 r23454 623 623 624 624 625 The `doctrine:build-filters` task creates f ilter formclasses from the schema:625 The `doctrine:build-filters` task creates form filter classes from the schema: 626 626 627 627 ./symfony doctrine:build-filters 628 628 629 The task read the schema information in `config/*schema.xml` and/or 630 `config/*schema.yml` from the project and all installed plugins. 631 632 The model filter form classes files are created in `lib/filter`. 633 634 This task never overrides custom classes in `lib/filter`. 635 It only replaces base classes generated in `lib/filter/base`. 629 This task creates form filter classes based on the model. The classes are 630 created in `lib/doctrine/filter`. 631 632 This task never overrides custom classes in `lib/doctrine/filter`. 633 It only replaces base classes generated in `lib/doctrine/filter/base`. 636 634 637 635 ### ~`doctrine::build-forms`~ … … 657 655 ./symfony doctrine:build-forms 658 656 659 The task read the schema information in `config/*schema.xml` and/or 660 `config/*schema.yml` from the project and all installed plugins. 661 662 The model form classes files are created in `lib/form`. 663 664 This task never overrides custom classes in `lib/form`. 665 It only replaces base classes generated in `lib/form/base`. 657 This task creates form classes based on the model. The classes are created 658 in `lib/doctrine/form`. 659 660 This task never overrides custom classes in `lib/doctrine/form`. 661 It only replaces base classes generated in `lib/doctrine/form/base`. 666 662 667 663 ### ~`doctrine::build-model`~ … … 686 682 687 683 The task read the schema information in `config/doctrine/*.yml` 688 from the project and all installed plugins.684 from the project and all enabled plugins. 689 685 690 686 The model classes files are created in `lib/model/doctrine`. … … 754 750 755 751 756 752 The `doctrine:clean-model-files` task deletes model classes that are not 753 represented in project or plugin schema.yml files: 754 755 ./symfony doctrine:clean-model-files 757 756 758 757 ### ~`doctrine::create-model-tables`~ … … 807 806 the `doctrine:data-load` task. 808 807 809 ./symfony doctrine:data-load frontend808 ./symfony doctrine:data-load 810 809 811 810 ### ~`doctrine::data-load`~ … … 863 862 864 863 865 864 The `doctrine:delete-model-files` task deletes all files associated with certain 865 models: 866 867 ./symfony doctrine:delete-model-files Article Author 866 868 867 869 ### ~`doctrine::dql`~ … … 915 917 ./symfony doctrine:drop-db 916 918 917 The task read connection information in `config/d octrine/databases.yml`:919 The task read connection information in `config/databases.yml`: 918 920 919 921 ### ~`doctrine::generate-admin`~ … … 921 923 The `doctrine::generate-admin` task generates a Doctrine admin module: 922 924 923 $ php symfony doctrine:generate-admin [--module="..."] [--theme="..."] [--singular="..."] [--plural="..."] [--env="..."] application route_or_model925 $ php symfony doctrine:generate-admin [--module="..."] [--theme="..."] [--singular="..."] [--plural="..."] [--env="..."] [--actions-base-class="..."] application route_or_model 924 926 925 927 … … 938 940 | `--plural` | `-` | The plural name 939 941 | `--env` | `dev` | The environment 942 | `--actions-base-class` | `sfActions` | The base class for the actions 940 943 941 944 … … 1010 1013 1011 1014 1012 The `doctrine:generate-migration` task generates migration classes from existing database connections 1013 1014 ./symfony doctrine:generate-migration 1015 The `doctrine:generate-migrations-db` task generates migration classes from 1016 existing database connections: 1017 1018 ./symfony doctrine:generate-migrations-db 1015 1019 1016 1020 ### ~`doctrine::generate-migrations-diff`~ … … 1030 1034 1031 1035 1032 The `doctrine:generate-migrations-diff` task generates migration classes by producing a diff between your old and new schema. 1036 The `doctrine:generate-migrations-diff` task generates migration classes by 1037 producing a diff between your old and new schema. 1033 1038 1034 1039 ./symfony doctrine:generate-migrations-diff … … 1050 1055 1051 1056 1052 The `doctrine:generate-migration` task generates migration classes from an existing set of models 1053 1054 ./symfony doctrine:generate-migration 1057 The `doctrine:generate-migrations-models` task generates migration classes 1058 from an existing set of models: 1059 1060 ./symfony doctrine:generate-migrations-models 1055 1061 1056 1062 ### ~`doctrine::generate-module`~ … … 1058 1064 The `doctrine::generate-module` task generates a Doctrine module: 1059 1065 1060 $ php symfony doctrine:generate-module [--theme="..."] [--generate-in-cache] [--non-verbose-templates] [--with-show] [--singular="..."] [--plural="..."] [--route-prefix="..."] [--with-doctrine-route] [--env="..."] application module model1066 $ php symfony doctrine:generate-module [--theme="..."] [--generate-in-cache] [--non-verbose-templates] [--with-show] [--singular="..."] [--plural="..."] [--route-prefix="..."] [--with-doctrine-route] [--env="..."] [--actions-base-class="..."] application module model 1061 1067 1062 1068 *Alias(es)*: `doctrine-generate-crud, doctrine:generate-crud` … … 1080 1086 | `--with-doctrine-route` | `-` | Whether you will use a Doctrine route 1081 1087 | `--env` | `dev` | The environment 1088 | `--actions-base-class` | `sfActions` | The base class for the actions 1082 1089 1083 1090 … … 1101 1108 This way, you can create your very own module generator with your own conventions. 1102 1109 1110 You can also change the default actions base class (default to sfActions) of 1111 the generated modules: 1112 1113 ./symfony doctrine:generate-module --actions-base-class="ProjectActions" frontend article Article 1114 1103 1115 ### ~`doctrine::generate-module-for-route`~ 1104 1116 1105 1117 The `doctrine::generate-module-for-route` task generates a Doctrine module for a route definition: 1106 1118 1107 $ php symfony doctrine:generate-module-for-route [--theme="..."] [--non-verbose-templates] [--singular="..."] [--plural="..."] [--env="..."] application route1119 $ php symfony doctrine:generate-module-for-route [--theme="..."] [--non-verbose-templates] [--singular="..."] [--plural="..."] [--env="..."] [--actions-base-class="..."] application route 1108 1120 1109 1121 … … 1122 1134 | `--plural` | `-` | The plural name 1123 1135 | `--env` | `dev` | The environment 1136 | `--actions-base-class` | `sfActions` | The base class for the actions 1124 1137 1125 1138 … … 1152 1165 1153 1166 The task connects to the database and creates tables for all the 1154 `lib/model/doctrine/*. php` files.1167 `lib/model/doctrine/*.class.php` files. 1155 1168 1156 1169 ### ~`doctrine::migrate`~ … … 1215 1228 ./symfony doctrine:rebuild-db 1216 1229 1217 The task read connection information in `config/d octrine/databases.yml`:1230 The task read connection information in `config/databases.yml`: 1218 1231 1219 1232 Include the `--migrate` option if you would like to run your application's … … 1242 1255 1243 1256 1244 The `doctrine:reload-data` task drops the database, recreates it and loads fixtures1245 Call it with:1257 The `doctrine:reload-data` task drops the database, recreates it and loads 1258 fixtures: 1246 1259 1247 1260 php symfony doctrine:reload-data … … 1306 1319 ./symfony generate:app frontend --csrf-secret=UniqueSecret 1307 1320 1321 You can customize the default skeleton used by the task by creating a 1322 `%sf_data_dir%/skeleton/app` directory. 1308 1323 1309 1324 ### ~`generate::module`~ … … 1349 1364 The `generate::project` task generates a new project: 1350 1365 1351 $ php symfony generate:project [--orm="..."] [--installer="..."] name 1366 $ php symfony generate:project [--orm="..."] [--installer="..."] name [author] 1352 1367 1353 1368 *Alias(es)*: `init-project` … … 1356 1371 | -------- | ------- | ----------- 1357 1372 | `name` | `-` | The project name 1373 | `author` | `Your name here` | The project author 1358 1374 1359 1375 … … 1385 1401 1386 1402 ./symfony generate:project blog --installer=./installer.php 1403 1404 You can optionally include a second `author` argument to specify what name to 1405 use as author when symfony generates new classes: 1406 1407 ./symfony generate:project blog "Jack Doe" 1387 1408 1388 1409 ### ~`generate::task`~ … … 1868 1889 ./symfony project:deploy --go --rsync-dir=config/production production 1869 1890 1870 Last, you can specify the options passed to the rsync executable, using the 1871 `rsync-options` option (defaults are `-azC `):1872 1873 ./symfony project:deploy --go --rsync-options= avz1891 Last, you can specify the options passed to the rsync executable, using the 1892 `rsync-options` option (defaults are `-azC --force --delete --progress`): 1893 1894 ./symfony project:deploy --go --rsync-options=-avz 1874 1895 1875 1896 ### ~`project::disable`~ … … 1927 1948 The `project::optimize` task optimizes a project for better performance: 1928 1949 1929 $ php symfony project:optimize [env] [app1] ... [appN]1930 1931 1932 1933 | Argument | Default | Description 1934 | -------- | ------- | ----------- 1935 | ` env` | `prod` | The environmentname1936 | ` app` | `-` | The applicationname1950 $ php symfony project:optimize application [environment] 1951 1952 1953 1954 | Argument | Default | Description 1955 | -------- | ------- | ----------- 1956 | `application` | `-` | The server name 1957 | `environment` | `prod` | The server name 1937 1958 1938 1959 … … 1941 1962 The `project:optimize` optimizes a project for better performance: 1942 1963 1943 ./symfony project:optimize 1964 ./symfony project:optimizes frontend prod 1944 1965 1945 1966 This task should only be used on a production server. Don't forget to re-run 1946 1967 the task each time the project changes. 1947 1948 You can specify an environment other than `prod` by passing it as an1949 argument:1950 1951 ./symfony project:optimize staging1952 1953 You can further specify one or more applications to optimize by passing1954 additional arguments:1955 1956 ./symfony project:optimize prod frontend1957 1968 1958 1969 ### ~`project::permissions`~ … … 2417 2428 The `propel::generate-admin` task generates a Propel admin module: 2418 2429 2419 $ php symfony propel:generate-admin [--module="..."] [--theme="..."] [--singular="..."] [--plural="..."] [--env="..."] application route_or_model2430 $ php symfony propel:generate-admin [--module="..."] [--theme="..."] [--singular="..."] [--plural="..."] [--env="..."] [--actions-base-class="..."] application route_or_model 2420 2431 2421 2432 … … 2434 2445 | `--plural` | `-` | The plural name 2435 2446 | `--env` | `dev` | The environment 2447 | `--actions-base-class` | `sfActions` | The base class for the actions 2436 2448 2437 2449 … … 2465 2477 The `propel::generate-module` task generates a Propel module: 2466 2478 2467 $ php symfony propel:generate-module [--theme="..."] [--generate-in-cache] [--non-verbose-templates] [--with-show] [--singular="..."] [--plural="..."] [--route-prefix="..."] [--with-propel-route] [--env="..."] application module model2479 $ php symfony propel:generate-module [--theme="..."] [--generate-in-cache] [--non-verbose-templates] [--with-show] [--singular="..."] [--plural="..."] [--route-prefix="..."] [--with-propel-route] [--env="..."] [--actions-base-class="..."] application module model 2468 2480 2469 2481 *Alias(es)*: `propel-generate-crud, propel:generate-crud` … … 2487 2499 | `--with-propel-route` | `-` | Whether you will use a Propel route 2488 2500 | `--env` | `dev` | The environment 2501 | `--actions-base-class` | `sfActions` | The base class for the actions 2489 2502 2490 2503 … … 2508 2521 This way, you can create your very own module generator with your own conventions. 2509 2522 2523 You can also change the default actions base class (default to sfActions) of 2524 the generated modules: 2525 2526 ./symfony propel:generate-module --actions-base-class="ProjectActions" frontend article Article 2527 2510 2528 ### ~`propel::generate-module-for-route`~ 2511 2529 2512 2530 The `propel::generate-module-for-route` task generates a Propel module for a route definition: 2513 2531 2514 $ php symfony propel:generate-module-for-route [--theme="..."] [--non-verbose-templates] [--singular="..."] [--plural="..."] [--env="..."] application route2532 $ php symfony propel:generate-module-for-route [--theme="..."] [--non-verbose-templates] [--singular="..."] [--plural="..."] [--env="..."] [--actions-base-class="..."] application route 2515 2533 2516 2534 … … 2529 2547 | `--plural` | `-` | The plural name 2530 2548 | `--env` | `dev` | The environment 2549 | `--actions-base-class` | `sfActions` | The base class for the actions 2531 2550 2532 2551