grav/system/defines.php

54 lines
1.5 KiB
PHP
Raw Normal View History

2014-08-02 21:11:33 +02:00
<?php
2016-07-12 00:07:14 +02:00
/**
* @package Grav.Core
*
2017-12-11 23:08:05 +01:00
* @copyright Copyright (C) 2015 - 2018 Trilby Media, LLC. All rights reserved.
2016-07-12 00:07:14 +02:00
* @license MIT License; see LICENSE file for details.
*/
2014-08-02 21:11:33 +02:00
// Some standard defines
define('GRAV', true);
2019-01-31 01:35:30 +01:00
define('GRAV_VERSION', '1.6.0-rc.1');
define('GRAV_TESTING', true);
2014-08-02 21:11:33 +02:00
define('DS', '/');
2017-02-16 10:37:35 +01:00
if (!defined('GRAV_PHP_MIN')) {
define('GRAV_PHP_MIN', '7.1.3');
2017-02-16 10:37:35 +01:00
}
2014-08-02 21:11:33 +02:00
// Directories and Paths
if (!defined('GRAV_ROOT')) {
2015-04-08 19:20:11 +02:00
define('GRAV_ROOT', str_replace(DIRECTORY_SEPARATOR, DS, getcwd()));
2014-08-02 21:11:33 +02:00
}
define('ROOT_DIR', GRAV_ROOT . '/');
2014-08-02 21:11:33 +02:00
define('USER_PATH', 'user/');
define('USER_DIR', ROOT_DIR . USER_PATH);
define('CACHE_DIR', ROOT_DIR . 'cache/');
2014-08-02 21:11:33 +02:00
// DEPRECATED: Do not use!
define('ASSETS_DIR', ROOT_DIR . 'assets/');
define('IMAGES_DIR', ROOT_DIR . 'images/');
define('ACCOUNTS_DIR', USER_DIR .'accounts/');
define('PAGES_DIR', USER_DIR .'pages/');
define('DATA_DIR', USER_DIR .'data/');
2016-03-31 13:03:43 +02:00
define('SYSTEM_DIR', ROOT_DIR .'system/');
define('LIB_DIR', SYSTEM_DIR .'src/');
2014-08-02 21:11:33 +02:00
define('PLUGINS_DIR', USER_DIR .'plugins/');
define('THEMES_DIR', USER_DIR .'themes/');
define('VENDOR_DIR', ROOT_DIR .'vendor/');
define('LOG_DIR', ROOT_DIR .'logs/');
// END DEPRECATED
2014-08-02 21:11:33 +02:00
// Some extensions
define('CONTENT_EXT', '.md');
define('TEMPLATE_EXT', '.html.twig');
define('TWIG_EXT', '.twig');
define('PLUGIN_EXT', '.php');
define('YAML_EXT', '.yaml');
// Content types
define('RAW_CONTENT', 1);
define('TWIG_CONTENT', 2);
define('TWIG_CONTENT_LIST', 3);
define('TWIG_TEMPLATES', 4);