From eb4c287da06162a767ea1eef7372ec53c6f432ab Mon Sep 17 00:00:00 2001 From: fancl Date: Mon, 23 Oct 2023 15:44:44 +0800 Subject: [PATCH] add name and version --- instance.go | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/instance.go b/instance.go index 2eb5e11..becd546 100644 --- a/instance.go +++ b/instance.go @@ -40,6 +40,16 @@ func Http() *http.Server { return std.Http() } +func Name() string { + initApplication() + return std.opts.Name +} + +func Version() string { + initApplication() + return std.opts.Version +} + func Debug() bool { initApplication() return std.opts.EnableDebug