summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJonas Kohl2024-10-19 16:14:51 +0200
committerJonas Kohl2024-10-19 16:14:51 +0200
commit6687b7dee8201b1db5b9c2b0560f126a697ff3ab (patch)
tree662b91d82489c2cefacebdd3977afdf6c0c2cd9d /src
parentd19ee8eb03f0cd89cf75cd148dc02f86841181a6 (diff)
Add version CLI commandv0.6.1
Diffstat (limited to 'src')
-rw-r--r--src/application/appdef.php3
-rw-r--r--src/bin/.htaccess1
-rwxr-xr-xsrc/bin/version6
-rw-r--r--src/index.php2
4 files changed, 11 insertions, 1 deletions
diff --git a/src/application/appdef.php b/src/application/appdef.php
new file mode 100644
index 0000000..7cddfff
--- /dev/null
+++ b/src/application/appdef.php
@@ -0,0 +1,3 @@
+<?php
+
+const MYSTICBB_VERSION = "0.6.1";
diff --git a/src/bin/.htaccess b/src/bin/.htaccess
new file mode 100644
index 0000000..b66e808
--- /dev/null
+++ b/src/bin/.htaccess
@@ -0,0 +1 @@
+Require all denied
diff --git a/src/bin/version b/src/bin/version
new file mode 100755
index 0000000..18ad91f
--- /dev/null
+++ b/src/bin/version
@@ -0,0 +1,6 @@
+#!/usr/bin/env php
+<?php
+
+include __DIR__ . "/../application/appdef.php";
+
+echo MYSTICBB_VERSION;
diff --git a/src/index.php b/src/index.php
index 356eb86..4c53f0c 100644
--- a/src/index.php
+++ b/src/index.php
@@ -18,7 +18,7 @@ use Twig\TwigFunction;
header_remove("X-Powered-By");
-const MYSTICBB_VERSION = "0.6.0";
+include __DIR__ . "/application/appdef.php";
if (($_SERVER["HTTP_USER_AGENT"] ?? "") === "") {
http_response_code(403);