* adjust the packing of syun version.

This commit is contained in:
wangchunsheng
2012-07-27 02:57:29 +00:00
parent 7cf5d68a1c
commit b6ac217b20
3 changed files with 30 additions and 25 deletions

View File

@@ -87,7 +87,7 @@ build4sae:
# change the logic of merge model file in helper.class.php.
sed -e 's/\$$app->getTmpRoot/"saemc:\/\/" . \$$app\-\>getTmpRoot/g' zentaopms/framework/helper.class.php >zentaopms/framework/helper.class.new
mv zentaopms/framework/helper.class.new zentaopms/framework/helper.class.php
cp build/sae/my.php zentaopms/config/my.php
cp build/sae/mysae.php zentaopms/config/my.php
cp build/sae/sae_app_wizard.xml zentaopms/
# get the extension files.
svn export https://svn.cnezsoft.com/easysoft/trunk/zentaoext/sae
@@ -108,9 +108,8 @@ build4yunshangdian:
rm -fr zentaopms/tmp
rm -fr zentaopms/data
# copy the my.php
cp build/sae/my.php zentaopms/config/my.php
sed -e 's/PATH_INFO/GET/g' build/sae/my.php > zentaopms/config/my.php
mkdir zentaopms/config/ext
cp build/sae/mysyun.php zentaopms/config/ext/syun.php
# copy the wizard.xml.
grep -v 'Storage' build/sae/sae_app_wizard.xml | grep -v 'Memcache' > zentaopms/sae_app_wizard.xml
# get the extension files.

View File

@@ -29,25 +29,3 @@ $saeDB = new saemysql();
$saeSQL = "SELECT COUNT(`id`) FROM `" . $config->db->prefix . "config` WHERE 1 LIMIT 0,10";
if($saeDB->getData($saeSQL)) $config->installed = true;
$saeDB->closeDb();
$appRoot = dirname(dirname(__FILE__)) . '/' ;
$htaccessFile = $appRoot . 'htaccess';
if(file_exists($htaccessFile)) rename($htaccessFile, str_replace('htaccess', '.htaccss', $htaccessFile));
$tmpRoot = $appRoot . '/tmp/';
if(!is_dir($tmpRoot))
{
mkdir($tmpRoot, 0777);
mkdir($tmpRoot . 'cache', 0777);
mkdir($tmpRoot . 'extension', 0777);
mkdir($tmpRoot . 'log', 0777);
mkdir($tmpRoot . 'model', 0777);
mkdir($tmpRoot . 'svn', 0777);
}
$dataRoot = $appRoot . 'data/';
if(!is_dir($dataRoot))
{
mkdir($dataRoot, 0777);
mkdir($dataRoot . 'upload', 0777);
}

28
build/sae/mysyun.php Executable file
View File

@@ -0,0 +1,28 @@
<?php
$appRoot = dirname(dirname(dirname(__FILE__))) . '/' ;
$sourceHtaccessFile = $appRoot . 'htaccess';
$targetHtaccessFile = $appRoot . '.htaccess';
if(file_exists($sourceHtaccessFile))
{
$targetHtaccessCode = str_replace('index.php', $config->webRoot . 'index.php', file_get_contents($sourceHtaccessFile));
file_put_contents($targetHtaccessFile, $targetHtaccessCode);
}
$tmpRoot = $appRoot . '/tmp/';
if(!is_dir($tmpRoot))
{
mkdir($tmpRoot, 0777);
mkdir($tmpRoot . 'cache', 0777);
mkdir($tmpRoot . 'extension', 0777);
mkdir($tmpRoot . 'log', 0777);
mkdir($tmpRoot . 'model', 0777);
mkdir($tmpRoot . 'svn', 0777);
}
$dataRoot = $appRoot . 'data/';
if(!is_dir($dataRoot))
{
mkdir($dataRoot, 0777);
mkdir($dataRoot . 'upload', 0777);
}