Ophestra Umiker
6bc5be7e5a
All checks were successful
test / test (push) Successful in 19s
This change helps tests stub out and simulate OS behaviour during the sealing process. This also removes dependency on XDG_RUNTIME_DIR as the internal.System implementation provided to App provides a compat directory inside the tmpdir-based share when XDG_RUNTIME_DIR is unavailable. Signed-off-by: Ophestra Umiker <cat@ophivana.moe>
26 lines
278 B
Go
26 lines
278 B
Go
package main
|
|
|
|
import (
|
|
_ "embed"
|
|
"flag"
|
|
"fmt"
|
|
)
|
|
|
|
var (
|
|
//go:embed LICENSE
|
|
license string
|
|
|
|
printLicense bool
|
|
)
|
|
|
|
func init() {
|
|
flag.BoolVar(&printLicense, "license", false, "Print license")
|
|
}
|
|
|
|
func tryLicense() {
|
|
if printLicense {
|
|
fmt.Println(license)
|
|
os.Exit(0)
|
|
}
|
|
}
|