aboutsummaryrefslogtreecommitdiff
path: root/cmd/galleryd/log.go
diff options
context:
space:
mode:
authorSaiyed Shizain <saiyedshizain@gmail.com>2026-07-13 20:21:01 +0530
committerGitHub <noreply@github.com>2026-07-13 20:21:01 +0530
commitccd5a186594d9e9d174cca862953ab8355c1312f (patch)
tree02e4356c671e3a71ef3910bd3c0635daf9d12aaa /cmd/galleryd/log.go
parent5d4eaf85434658f6fed621016e0bc2bae59e88d1 (diff)
parent72ef8ea5ac664b40b2b3cff632b821d8a06453c0 (diff)
downloadgalleryd-ccd5a186594d9e9d174cca862953ab8355c1312f.tar.xz
galleryd-ccd5a186594d9e9d174cca862953ab8355c1312f.zip
Merge pull request #9 from RanXom/feat/cli
Feat/cli: add commandline configuration
Diffstat (limited to 'cmd/galleryd/log.go')
-rw-r--r--cmd/galleryd/log.go15
1 files changed, 15 insertions, 0 deletions
diff --git a/cmd/galleryd/log.go b/cmd/galleryd/log.go
new file mode 100644
index 0000000..08c2065
--- /dev/null
+++ b/cmd/galleryd/log.go
@@ -0,0 +1,15 @@
+package main
+
+import (
+ "fmt"
+ "strings"
+)
+
+func listenURL(addr string) string {
+ switch {
+ case strings.HasPrefix(addr, ":"):
+ return fmt.Sprintf("http://localhost%s", addr)
+ default:
+ return fmt.Sprintf("http://%s", addr)
+ }
+}