Convert BuildConstants constants to enum cases
This commit is contained in:
parent
492548d81f
commit
87a8ca24a1
2 changed files with 9 additions and 9 deletions
|
@ -121,10 +121,10 @@
|
||||||
|
|
||||||
return str_replace(
|
return str_replace(
|
||||||
[
|
[
|
||||||
BuildConstants::COMPILE_TIMESTAMP,
|
BuildConstants::COMPILE_TIMESTAMP->value,
|
||||||
BuildConstants::NCC_BUILD_VERSION,
|
BuildConstants::NCC_BUILD_VERSION->value,
|
||||||
BuildConstants::NCC_BUILD_FLAGS,
|
BuildConstants::NCC_BUILD_FLAGS->value,
|
||||||
BuildConstants::NCC_BUILD_BRANCH
|
BuildConstants::NCC_BUILD_BRANCH->value
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
time(),
|
time(),
|
||||||
|
|
|
@ -22,25 +22,25 @@
|
||||||
|
|
||||||
namespace ncc\Enums\SpecialConstants;
|
namespace ncc\Enums\SpecialConstants;
|
||||||
|
|
||||||
final class BuildConstants
|
enum BuildConstants : string
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* The Unix Timestamp for when the package was compiled
|
* The Unix Timestamp for when the package was compiled
|
||||||
*/
|
*/
|
||||||
public const COMPILE_TIMESTAMP = '%COMPILE_TIMESTAMP%';
|
case COMPILE_TIMESTAMP = '%COMPILE_TIMESTAMP%';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The version of NCC that was used to compile the package
|
* The version of NCC that was used to compile the package
|
||||||
*/
|
*/
|
||||||
public const NCC_BUILD_VERSION = '%NCC_BUILD_VERSION%';
|
case NCC_BUILD_VERSION = '%NCC_BUILD_VERSION%';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* NCC Build Flags exploded into spaces
|
* NCC Build Flags exploded into spaces
|
||||||
*/
|
*/
|
||||||
public const NCC_BUILD_FLAGS = '%NCC_BUILD_FLAGS%';
|
case NCC_BUILD_FLAGS = '%NCC_BUILD_FLAGS%';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* NCC Build Branch
|
* NCC Build Branch
|
||||||
*/
|
*/
|
||||||
public const NCC_BUILD_BRANCH = '%NCC_BUILD_BRANCH%';
|
case NCC_BUILD_BRANCH = '%NCC_BUILD_BRANCH%';
|
||||||
}
|
}
|
Loading…
Add table
Reference in a new issue