castopod/app/Config/Constants.php
semantic-release-bot c9fabe8888 chore(release): 2.0.0-next.3 [skip ci]
## [2.0.0-next.3](https://code.castopod.org/adaures/castopod/compare/v2.0.0-next.2...v2.0.0-next.3) (2024-12-30)

### Features

* **api:** add Episode create and publish endpoints ([a90cdfd](a90cdfdcdb))
* **image:** add image size's width and height ([f50098e](f50098ec89))
* **plugins:** add defaultValue for all field types ([d3a98db](d3a98db6d0))
* **plugins:** add group field type + multiple option to render field arrays ([11ccd0e](11ccd0ebe7))
* **plugins:** add html field type + CodeEditor component + rework html head generation ([8cf9c6d](8cf9c6dc83))
* **rss:** add option for 301 redirect to new feed url ([8402cc2](8402cc29d2))

### Bug Fixes

* add downloads_count to episodes table, computed every hour ([f981937](f981937645))
* allow passing json to app.proxyIPs config to set it ([cbf739e](cbf739e95c))
* **api:** cast integers when creating episode ([775b302](775b302f7c))
* **docker-image:** clear cache to account for new assets and data structure changes ([63c763f](63c763f941)), closes [#510](https://code.castopod.org/adaures/castopod/issues/510)
* edit remap functions to get episode in episode admin controllers ([9f74cca](9f74cca342))
* **episode:** do not change slug when editing episode title ([a83afb0](a83afb0004)), closes [#513](https://code.castopod.org/adaures/castopod/issues/513)
* **fediverse:** add "processing" and "failed" statuses to better manage broadcast load ([1d7583d](1d7583d738)), closes [#511](https://code.castopod.org/adaures/castopod/issues/511)
* **icons:** set correct names for lock and lock-unlock icons in premium banner ([37ee6d3](37ee6d35b4))
* **plugins:** clear cache after activating or deactivating plugin ([08c7df2](08c7df2a5d))
* **plugins:** delete relevant cache when submitting settings ([00bd4c0](00bd4c02ee))
* **podcast-model:** always query podcast from database when clearing cache ([d30c49c](d30c49cdff))
* **premium-podcasts:** update query to validate subscription ([2b1bbf3](2b1bbf3430))
* **preview:** delete episode preview cache after editing episode ([732d429](732d42923d)), closes [#514](https://code.castopod.org/adaures/castopod/issues/514)
* **release:** add conventional-changelog-conventionalcommits for CHANGELOG generation ([6934c8a](6934c8aa8f))
* **rss:** add subscription id to cache name to prevent premium feeds from overlapping ([74f9325](74f9325946))
* set user as www-data when running cron jobs in docker's supervisord config ([65d74f1](65d74f14e6))
* typo in EpisodeController remap function to get episode ([f288a75](f288a750f5))
* update select and multi-select options to value/label arrays ([63f93f5](63f93f585b))

### Internal

* **plugins:** create Field objects per field type in settings forms + handle rendering in class ([34be5bc](34be5bccab))
* remove fields from podcast and episode entities to be replaced with plugins ([b869acb](b869acb3a9))
* rename controller methods for views and actions to be more consistent ([85704bf](85704bfbe0))
* update CodeIgniter to v4.5.6 ([f295e9a](f295e9aa4c))
* update codigniter-icons to v1.0.1 ([fa6967e](fa6967e65c))
* update js dependencies to latest ([70c9797](70c97971fc))
2024-12-30 12:31:21 +00:00

122 lines
4.6 KiB
PHP

<?php
declare(strict_types=1);
/*
| --------------------------------------------------------------------
| Castopod Version
| --------------------------------------------------------------------
|
| The Castopod version number to display.
|
| NOTE: this constant is updated upon release with Continuous Integration.
*/
defined('CP_VERSION') || define('CP_VERSION', '2.0.0-next.3');
/*
| --------------------------------------------------------------------
| App Namespace
| --------------------------------------------------------------------
|
| This defines the default Namespace that is used throughout
| CodeIgniter to refer to the Application directory. Change
| this constant to change the namespace that all application
| classes should use.
|
| NOTE: changing this will require manually modifying the
| existing namespaces of App* namespaced-classes.
*/
defined('APP_NAMESPACE') || define('APP_NAMESPACE', 'App');
/*
| --------------------------------------------------------------------
| Plugins Path
| --------------------------------------------------------------------
|
| This defines the folder in which plugins will live.
*/
defined('PLUGINS_PATH') ||
define('PLUGINS_PATH', ROOTPATH . 'plugins' . DIRECTORY_SEPARATOR);
defined('PLUGINS_KEY_PATTERN') ||
define('PLUGINS_KEY_PATTERN', '[a-z0-9]([_.-]?[a-z0-9]+)*\/[a-z0-9]([_.-]?[a-z0-9]+)*');
/*
| --------------------------------------------------------------------------
| Composer Path
| --------------------------------------------------------------------------
|
| The path that Composer's autoload file is expected to live. By default,
| the vendor folder is in the Root directory, but you can customize that here.
*/
defined('COMPOSER_PATH') ||
define('COMPOSER_PATH', ROOTPATH . 'vendor/autoload.php');
/*
|--------------------------------------------------------------------------
| Timing Constants
|--------------------------------------------------------------------------
|
| Provide simple ways to work with the myriad of PHP functions that
| require information to be in seconds.
*/
defined('SECOND') || define('SECOND', 1);
defined('MINUTE') || define('MINUTE', 60);
defined('HOUR') || define('HOUR', 3600);
defined('DAY') || define('DAY', 86400);
defined('WEEK') || define('WEEK', 604800);
defined('MONTH') || define('MONTH', 2_592_000);
defined('YEAR') || define('YEAR', 31_536_000);
defined('DECADE') || define('DECADE', 315_360_000);
/*
| --------------------------------------------------------------------------
| Exit Status Codes
| --------------------------------------------------------------------------
|
| Used to indicate the conditions under which the script is exit()ing.
| While there is no universal standard for error codes, there are some
| broad conventions. Three such conventions are mentioned below, for
| those who wish to make use of them. The CodeIgniter defaults were
| chosen for the least overlap with these conventions, while still
| leaving room for others to be defined in future versions and user
| applications.
|
| The three main conventions used for determining exit status codes
| are as follows:
|
| Standard C/C++ Library (stdlibc):
| http://www.gnu.org/software/libc/manual/html_node/Exit-Status.html
| (This link also contains other GNU-specific conventions)
| BSD sysexits.h:
| http://www.gsp.com/cgi-bin/man.cgi?section=3&topic=sysexits
| Bash scripting:
| http://tldp.org/LDP/abs/html/exitcodes.html
|
*/
defined('EXIT_SUCCESS') || define('EXIT_SUCCESS', 0); // no errors
defined('EXIT_ERROR') || define('EXIT_ERROR', 1); // generic error
defined('EXIT_CONFIG') || define('EXIT_CONFIG', 3); // configuration error
defined('EXIT_UNKNOWN_FILE') || define('EXIT_UNKNOWN_FILE', 4); // file not found
defined('EXIT_UNKNOWN_CLASS') || define('EXIT_UNKNOWN_CLASS', 5); // unknown class
defined('EXIT_UNKNOWN_METHOD') || define('EXIT_UNKNOWN_METHOD', 6); // unknown class member
defined('EXIT_USER_INPUT') || define('EXIT_USER_INPUT', 7); // invalid user input
defined('EXIT_DATABASE') || define('EXIT_DATABASE', 8); // database error
defined('EXIT__AUTO_MIN') || define('EXIT__AUTO_MIN', 9); // lowest automatically-assigned error code
defined('EXIT__AUTO_MAX') || define('EXIT__AUTO_MAX', 125); // highest automatically-assigned error code
/**
* @deprecated Use \CodeIgniter\Events\Events::PRIORITY_LOW instead.
*/
define('EVENT_PRIORITY_LOW', 200);
/**
* @deprecated Use \CodeIgniter\Events\Events::PRIORITY_NORMAL instead.
*/
define('EVENT_PRIORITY_NORMAL', 100);
/**
* @deprecated Use \CodeIgniter\Events\Events::PRIORITY_HIGH instead.
*/
define('EVENT_PRIORITY_HIGH', 10);