* code for task#1025.
This commit is contained in:
@@ -1,2 +0,0 @@
|
||||
php backup.php
|
||||
pause
|
||||
2
bin/bat/backup.bat
Executable file
2
bin/bat/backup.bat
Executable file
@@ -0,0 +1,2 @@
|
||||
php ../php/backup.php
|
||||
pause
|
||||
2
bin/bat/checkdb.bat
Executable file
2
bin/bat/checkdb.bat
Executable file
@@ -0,0 +1,2 @@
|
||||
php ../php/checkdb.php
|
||||
pause
|
||||
2
bin/bat/computeburn.bat
Executable file
2
bin/bat/computeburn.bat
Executable file
@@ -0,0 +1,2 @@
|
||||
php ../php/computeburn.php
|
||||
pause
|
||||
2
bin/bat/getbugs.bat
Executable file
2
bin/bat/getbugs.bat
Executable file
@@ -0,0 +1,2 @@
|
||||
php ../php/getbugs.php
|
||||
pause
|
||||
2
bin/bat/todo.bat
Executable file
2
bin/bat/todo.bat
Executable file
@@ -0,0 +1,2 @@
|
||||
php ../php/todo.php
|
||||
pause
|
||||
1
bin/bat/ztcli.bat
Normal file
1
bin/bat/ztcli.bat
Normal file
@@ -0,0 +1 @@
|
||||
php ../php/ztcli %*
|
||||
@@ -1,2 +0,0 @@
|
||||
php checkdb.php
|
||||
pause
|
||||
@@ -1,17 +0,0 @@
|
||||
<?php
|
||||
error_reporting(E_ERROR);
|
||||
include dirname(dirname(__FILE__)) . "/config/my.php";
|
||||
|
||||
if($config->requestType == 'PATH_INFO')
|
||||
{
|
||||
system('php ztcli "http://localhost/admin-checkdb"', $requestVar);
|
||||
}
|
||||
elseif($config->requestType == 'GET')
|
||||
{
|
||||
system('php ztcli "http://localhost/?m=admin&f=checkdb"', $requestVar);
|
||||
}
|
||||
|
||||
if(!$requestVar)
|
||||
{
|
||||
echo "Check DataBase successfully!\n";
|
||||
}
|
||||
@@ -1,2 +0,0 @@
|
||||
php computeburn.php
|
||||
pause
|
||||
@@ -1,2 +0,0 @@
|
||||
php getbugs.php
|
||||
pause
|
||||
@@ -3,7 +3,7 @@
|
||||
error_reporting(E_ERROR);
|
||||
|
||||
/* Include my.php and pclzip class. */
|
||||
$pmsRoot = dirname(dirname(__FILE__));
|
||||
$pmsRoot = dirname(dirname(dirname(__FILE__)));
|
||||
include $pmsRoot . '/config/my.php';
|
||||
include $pmsRoot . '/lib/pclzip/pclzip.class.php';
|
||||
|
||||
@@ -56,7 +56,7 @@ else
|
||||
}
|
||||
|
||||
/* Backup the data. */
|
||||
chdir(dirname(dirname(__FILE__)) . "/www");
|
||||
chdir(dirname(dirname(dirname(__FILE__))) . "/www");
|
||||
if(!is_dir('data/upload')) die(" No files needed backup.\n");
|
||||
|
||||
$dataFile = $destDir . "/" . "file." . date('Ymd', time()) . ".zip";
|
||||
@@ -26,7 +26,7 @@ $pmsTagURL = $pmsURL . $pmsTag;
|
||||
|
||||
echo $phpTag . "'\t" . $pmsTag . "\n";
|
||||
|
||||
chdir('../release/');
|
||||
chdir('../../release/');
|
||||
echo `svn export $phpTagURL`;
|
||||
echo `svn export $pmsTagURL`;
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
class control {}
|
||||
|
||||
/* set module root path and included the resource of group module. */
|
||||
$moduleRoot = '../module/';
|
||||
$moduleRoot = '../../module/';
|
||||
include $moduleRoot . '/group/lang/resource.php';
|
||||
|
||||
$whiteList[] = 'api-getsessionid';
|
||||
@@ -81,8 +81,8 @@ foreach(glob($moduleRoot . '*') as $modulePath)
|
||||
|
||||
/* checking actions of every module. */
|
||||
echo '-------------lang checking-----------------' . "\n";
|
||||
include '../module/common/lang/zh-cn.php';
|
||||
include '../config/config.php';
|
||||
include '../../module/common/lang/zh-cn.php';
|
||||
include '../../config/config.php';
|
||||
foreach(glob($moduleRoot . '*') as $modulePath)
|
||||
{
|
||||
unset($lang);
|
||||
@@ -112,7 +112,7 @@ foreach(glob($moduleRoot . '*') as $modulePath)
|
||||
$key = trim($key);
|
||||
$lineNO = $lineNO + 1;
|
||||
echo "module $moduleName need checking, command is:";
|
||||
echo " vim -O +$lineNO ../module/$moduleName/lang/zh-cn.php +$lineNO ../module/$moduleName/lang/en.php \n";
|
||||
echo " vim -O +$lineNO ../../module/$moduleName/lang/zh-cn.php +$lineNO ../../module/$moduleName/lang/en.php \n";
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
include("../config/my.php");
|
||||
$demoSql = file("../db/demo.sql");
|
||||
include("../../config/my.php");
|
||||
$demoSql = file("../../db/demo.sql");
|
||||
$output = '';
|
||||
foreach($demoSql as $sql)
|
||||
{
|
||||
@@ -10,5 +10,5 @@ foreach($demoSql as $sql)
|
||||
strpos($sql, $config->db->prefix . 'group') === false
|
||||
) $output .= $sql;
|
||||
}
|
||||
file_put_contents("../db/demo.sql", $output);
|
||||
file_put_contents("../../db/demo.sql", $output);
|
||||
|
||||
17
bin/php/checkdb.php
Executable file
17
bin/php/checkdb.php
Executable file
@@ -0,0 +1,17 @@
|
||||
<?php
|
||||
error_reporting(E_ERROR);
|
||||
include dirname(dirname(dirname(__FILE__))) . "/config/my.php";
|
||||
|
||||
if($config->requestType == 'PATH_INFO')
|
||||
{
|
||||
system('php ../php/ztcli "http://localhost/admin-checkdb"', $requestVar);
|
||||
}
|
||||
elseif($config->requestType == 'GET')
|
||||
{
|
||||
system('php ../php/ztcli "http://localhost/?m=admin&f=checkdb"', $requestVar);
|
||||
}
|
||||
|
||||
if(!$requestVar)
|
||||
{
|
||||
echo "Check DataBase successfully!\n";
|
||||
}
|
||||
@@ -3,7 +3,7 @@
|
||||
if(count($argv) != 2) die("please set the yaml file.\n");
|
||||
$filename = $argv[1];
|
||||
if(!is_file($filename)) die("the yaml file doesn't exit\n");
|
||||
include '../lib/spyc/spyc.class.php';
|
||||
include '../../lib/spyc/spyc.class.php';
|
||||
$extension = Spyc::YAMLLoadString(file_get_contents($filename));
|
||||
|
||||
/* Basic info checking. */
|
||||
@@ -3,7 +3,7 @@
|
||||
$langType = 'zh-tw';
|
||||
$langDesc = 'zh-tw';
|
||||
if(empty($langType)) die('lang') . "\n";
|
||||
foreach(glob('../module/*') as $moduleName)
|
||||
foreach(glob('../../module/*') as $moduleName)
|
||||
{
|
||||
$moduleLangPath = realpath($moduleName) . '/lang/';
|
||||
$defaultLangFile = $moduleLangPath . 'zh-cn.php';
|
||||
@@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
error_reporting(E_ERROR);
|
||||
$pmsRoot = dirname(dirname(__FILE__));
|
||||
$pmsRoot = dirname(dirname(dirname(__FILE__)));
|
||||
include $pmsRoot . '/config/my.php';
|
||||
include $pmsRoot . '/lib/api/api.class.php';
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
$langType = $argv[1];
|
||||
$langDesc = $argv[2];
|
||||
if(empty($langType)) die('lang') . "\n";
|
||||
foreach(glob('../module/*') as $moduleName)
|
||||
foreach(glob('../../module/*') as $moduleName)
|
||||
{
|
||||
$moduleLangPath = realpath($moduleName) . '/lang/';
|
||||
$defaultLangFile = $moduleLangPath . 'zh-cn.php';
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
error_reporting(E_ALL);
|
||||
$langType = empty($argv[1]) ? 'zh-cn' : $argv[1];
|
||||
$modules = glob('../module/*');
|
||||
$modules = glob('../../module/*');
|
||||
$maxLength = 0;
|
||||
foreach($modules as $modulePath)
|
||||
{
|
||||
@@ -2,7 +2,7 @@
|
||||
<?php
|
||||
error_reporting(E_ERROR);
|
||||
/* 包含http客户端类,snoopy。在禅道lib/snoopy里面可以找到。*/
|
||||
$pmsRoot = dirname(dirname(__FILE__));
|
||||
$pmsRoot = dirname(dirname(dirname(__FILE__)));
|
||||
include $pmsRoot . '/config/my.php';
|
||||
include $pmsRoot . '/lib/snoopy/snoopy.class.php';
|
||||
|
||||
@@ -9,10 +9,10 @@
|
||||
* @version $Id$
|
||||
* @link http://www.zentao.net
|
||||
*/
|
||||
include '../config/config.php';
|
||||
include '../../config/config.php';
|
||||
|
||||
$modules = array();
|
||||
$moduleRoot = realpath('../module/') . '/';
|
||||
$moduleRoot = realpath('../../module/') . '/';
|
||||
|
||||
if(is_dir($moduleRoot))
|
||||
{
|
||||
@@ -3,7 +3,7 @@
|
||||
* This file is used to compress css and js files.
|
||||
*/
|
||||
|
||||
$baseDir = dirname(dirname(__FILE__));
|
||||
$baseDir = dirname(dirname(dirname(__FILE__)));
|
||||
|
||||
//--------------------------------- PROCESS JS FILES ------------------------------ //
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?php
|
||||
include '../config/config.php';
|
||||
include '../../config/config.php';
|
||||
connectDB();
|
||||
|
||||
$databases[] = 'zentao_03';
|
||||
@@ -2,7 +2,7 @@
|
||||
<?php
|
||||
error_reporting(E_ERROR);
|
||||
/* 包含http客户端类,snoopy。在禅道lib/snoopy里面可以找到。*/
|
||||
$pmsRoot = dirname(dirname(__FILE__));
|
||||
$pmsRoot = dirname(dirname(dirname(__FILE__)));
|
||||
include $pmsRoot . '/config/my.php';
|
||||
include $pmsRoot . '/lib/snoopy/snoopy.class.php';
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?php
|
||||
include dirname(dirname(__FILE__)) . "/config/my.php";
|
||||
include dirname(dirname(dirname(__FILE__))) . "/config/my.php";
|
||||
|
||||
if($config->requestType == 'PATH_INFO')
|
||||
{
|
||||
@@ -21,7 +21,7 @@ $request = parse_url(trim($argv[1]));
|
||||
$_SERVER['HTTP_HOST'] = $request['host'];
|
||||
|
||||
/* Load the framework. */
|
||||
chdir(dirname(__FILE__));
|
||||
chdir(dirname(dirname(__FILE__)));
|
||||
include '../framework/router.class.php';
|
||||
include '../framework/control.class.php';
|
||||
include '../framework/model.class.php';
|
||||
@@ -40,7 +40,7 @@ else
|
||||
}
|
||||
|
||||
/* Instance the app and run it. */
|
||||
$app = router::createApp('pms', dirname(dirname(__FILE__)));
|
||||
$app = router::createApp('pms', dirname(dirname(dirname(__FILE__))));
|
||||
$common = $app->loadCommon();
|
||||
$app->parseRequest();
|
||||
$app->loadModule();
|
||||
1
bin/shell/ztcli.sh
Executable file
1
bin/shell/ztcli.sh
Executable file
@@ -0,0 +1 @@
|
||||
php ../php/ztcli $*
|
||||
@@ -1,2 +0,0 @@
|
||||
php todo.php
|
||||
pause
|
||||
@@ -1 +0,0 @@
|
||||
php ztcli %*
|
||||
@@ -1 +0,0 @@
|
||||
php ztcli $*
|
||||
Reference in New Issue
Block a user