#!/usr/bin/php Installation Avec les options --help, -help, -h, et -?, vous obtiendrez cette aide. Utilisation : [action] action : --install : Configuration Lien symbolique 'log', 'tables', 'wkhtml' ); foreach ( $directories as $dir ) { if ( !file_exists(realpath(dirname(__FILE__)).'/../public/data/'.$dir) ) { echo "Erreur dossier ".$dir."\n"; } } //Répertoire temporaire if ( !file_exists(realpath(dirname(__FILE__)).'/../cache') ) { mkdir(realpath(dirname(__FILE__)).'/../cache'); } if ( !file_exists(realpath(dirname(__FILE__)).'/../cache/sessions') ) { mkdir(realpath(dirname(__FILE__)).'/../cache/sessions'); } } function writeConfig() { global $hostname; $arrayConfig = array( 'mysql.php', 'smtp.php', 'sphinx.php', 'stockage.php', ); foreach($arrayConfig as $config) { passthru('cp -v '. realpath(dirname(__FILE__)).'/'.$hostname.'/'.$config.' ' . realpath(dirname(__FILE__)).'/'.$config); } passthru('cp -v '.realpath(dirname(__FILE__)).'/'.$hostname.'/databases.ini '. realpath(dirname(__FILE__).'/../application/configs').'/'); require_once realpath(dirname(__FILE__)).'/config.php'; if ( !file_exists(realpath(dirname(__FILE__)).'/../public/data/') ) passthru('ln -s '.DOC_WEB_LOCAL.' '.realpath(dirname(__FILE__)).'/../public/data'); }