aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xprosody11
1 files changed, 11 insertions, 0 deletions
diff --git a/prosody b/prosody
index 577dc178..45d8836b 100755
--- a/prosody
+++ b/prosody
@@ -87,6 +87,17 @@ prosody.arg = arg;
prosody.events = require "util.events".new();
+-- Try to determine version
+local version_file = io.open((CFG_SOURCEDIR or ".").."/prosody.version");
+if version_file then
+ prosody.version = version_file:read("*a"):gsub("%s*$", "");
+ version_file:close();
+else
+ prosody.version = "unknown";
+end
+
+log("info", "Hello and welcome to Prosody version %s", prosody.version);
+
--- Load and initialise core modules
require "util.import"
require "core.xmlhandlers"