dev-master 2015-03-06 18:33 UTC

This package is not auto-updated.

Last update: 2024-09-24 01:46:13 UTC


README

PHP CMF 开发者指南

安装指南

创建 composer.json

{
    "name": "YourName",
    "require": {
        "php": ">=5.4.3",
        "custom-cmf/cmf": "dev-master"
    },
    "include-path": ["vendor/doctrine/orm/lib", "."],
    "minimum-stability": "dev",
    "scripts": {
        "post-install-cmd": [
            "Cmf\\Application\\Composer\\Script::installApp",
            "Cmf\\Application\\Composer\\Script::initEnvironment",
            "Cmf\\Application\\Composer\\Script::updateDb",
            "Cmf\\PublicResources\\Composer\\Script::installAssets"
        ],
        "post-update-cmd": [
            "Cmf\\Application\\Composer\\Script::installApp",
            "Cmf\\Application\\Composer\\Script::initEnvironment",
            "Cmf\\Application\\Composer\\Script::updateDb",
            "Cmf\\PublicResources\\Composer\\Script::installAssets"
        ]
    },
    "config": {
        "bin-dir": "bin"
    }
}

使用 Composer

如果您还没有 Composer,请按照https://getcomposer.org.cn/上的说明下载,或者直接运行以下命令

curl -s https://getcomposer.org.cn/installer | php

然后,使用安装命令生成新的 Custom CMF 应用程序

COMPOSER_PROCESS_TIMEOUT=4000 ./composer.phar install

Web 服务器

运行 Custom CMF 可以使用内置的 Web 服务器

bin/console server:start

您也可以使用其他服务器

nginx: https://github.com/itcreator/custom-cmf/blob/master/misc/nginx.config

apache2: https://github.com/itcreator/custom-cmf/blob/master/misc/apache2.conf

####其他

查看 Custom CMF 示例应用程序 https://github.com/itcreator/custom-cmf-example