From 53b23a865a209851d7360dac6962fa44c1aeed06 Mon Sep 17 00:00:00 2001 From: Thomas Voss Date: Fri, 13 Jun 2025 23:34:56 +0200 Subject: Normalize the current directory --- main.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/main.go b/main.go index 20c9fd6..f5c039a 100644 --- a/main.go +++ b/main.go @@ -7,6 +7,7 @@ import ( "flag" "log" "os" + "path/filepath" "syscall" "time" @@ -17,6 +18,8 @@ import ( ) func main() { + Try(os.Chdir(filepath.Dir(os.Args[0]))) + port := flag.Int("port", 8080, "port number") debugp := flag.Bool("debug", false, "run in debug mode") flag.BoolVar(&email.Config.Disabled, "no-email", false, -- cgit v1.2.3