phpci/vars.php

43 lines
1.2 KiB
PHP
Raw Normal View History

2013-10-10 02:01:06 +02:00
<?php
// Define our APPLICATION_PATH, if not already defined:
if (!defined('APPLICATION_PATH')) {
define('APPLICATION_PATH', dirname(__FILE__) . '/');
define('PHPCI_DIR', APPLICATION_PATH);
}
// Define our PHPCI_URL, if not already defined:
if (!defined('PHPCI_URL') && isset($config)) {
2013-10-10 02:01:06 +02:00
define('PHPCI_URL', $config->get('phpci.url', '') . '/');
}
// Define PHPCI_BIN_DIR
if (!defined('PHPCI_BIN_DIR')) {
define('PHPCI_BIN_DIR', PHPCI_DIR . 'vendor/bin/');
}
// Define PHPCI_BUILD_ROOT_DIR
if (!defined('PHPCI_BUILD_ROOT_DIR')) {
define('PHPCI_BUILD_ROOT_DIR', PHPCI_DIR . 'PHPCI/build/');
}
2013-10-10 02:01:06 +02:00
// Should PHPCI run the Shell plugin?
if (!defined('ENABLE_SHELL_PLUGIN')) {
define('ENABLE_SHELL_PLUGIN', false);
}
// If this is not already defined, we're not running in the console:
if (!defined('PHPCI_IS_CONSOLE')) {
define('PHPCI_IS_CONSOLE', false);
2013-10-10 02:12:30 +02:00
}
2014-03-12 18:37:57 +01:00
if (!defined('IS_WIN')) {
define('IS_WIN', ((strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') ? true : false));
2014-03-12 18:37:57 +01:00
}
2015-02-26 09:45:42 +01:00
// If an environment variable is set defining our config location, use that
// otherwise fall back to PHPCI/config.yml.
if (!defined('PHPCI_CONFIG_FILE')) {
define('PHPCI_CONFIG_FILE', $configFile);
2015-02-26 09:48:40 +01:00
}