Files
upscayl-server/configs/const.go
2026-05-20 00:43:37 +08:00

32 lines
536 B
Go

package configs
import (
"log"
"runtime"
)
var (
Platform string
BinaryName string
UpscaylPath string
)
func init() {
switch runtime.GOOS {
case "windows":
Platform = "windows"
BinaryName = "upscayl-bin.exe"
UpscaylPath = ".\\upscayl-bin.exe"
case "linux":
Platform = "linux"
BinaryName = "upscayl-bin"
UpscaylPath = "./upscayl-bin"
case "darwin":
Platform = "macos"
BinaryName = "upscayl-bin"
UpscaylPath = "./upscayl-bin"
default:
log.Fatalf("unsupported operating system: %s", runtime.GOOS)
}
}