config file reading logic implemented, project structure refined

This commit is contained in:
Maximilian Wagner
2025-12-24 00:26:32 +01:00
parent d30757808d
commit 2d50286efa
13 changed files with 181 additions and 3 deletions

25
globals/config.go Normal file
View File

@@ -0,0 +1,25 @@
package globals
import "sync"
type Config struct {
// general
LogLevel string `json:"logLevel"`
LogFilePath string `json:"logFilePath"`
// latex
LatexEngine string `json:"latexEngine"`
LatexSourceFilePath string `json:"latexSourceFilePath"`
LatexOutputPath string `json:"latexOutputPath"`
// webserver
WebserverDomain string `json:"webserverDomain"`
WebserverSecure bool `json:"webserverSecure"`
CertificatePath string `json:"certificatePath"`
CertificateKeyPath string `json:"certificateKeyPath"`
// to prevent competing compiles, not actual configuration
ExecutionLock sync.Mutex
}
var AppConfig Config