ppforge/globals/globals.windows.go

23 lines
565 B
Go
Raw Normal View History

2023-10-13 16:13:33 +02:00
package globals
// Global variables, Mocks, etc.
// This package shall not have any dependency towards the application itself!
import (
2023-10-27 13:38:35 +02:00
"log"
2023-10-13 16:13:33 +02:00
"path"
)
func init() {
2023-10-27 13:38:35 +02:00
user, err := MockUserCurrent()
if err != nil {
log.Printf("Current user not obtainable: %s", err)
log.Fatal("Impossible to open default database")
}
2023-10-13 16:13:33 +02:00
// ConfigDirectoryList Configuration directory list Windows TODO
2023-10-27 13:38:35 +02:00
ConfigDirectoryList = []string{user.HomeDir /*TODO!!!*/}
2023-10-13 16:13:33 +02:00
// ConfigDirectory Configuration directory string Windows
2023-10-27 13:38:35 +02:00
ConfigDirectory = path.Join(ConfigDirectoryList...)
2023-10-13 16:13:33 +02:00
}