Add version and startup message

This commit is contained in:
Torjus Håkestad 2024-03-10 03:24:11 +01:00
parent 94c9c76eac
commit 4ebf6dd715

View File

@ -11,6 +11,8 @@ import (
"github.com/holoplot/go-evdev"
)
const Version = "v0.1.1"
func main() {
// Setup logger
h := slog.NewJSONHandler(os.Stdout, &slog.HandlerOptions{Level: slog.LevelInfo})
@ -48,6 +50,7 @@ func main() {
}()
// Start listening for PTT key
slog.Info("Starting event listener", "version", Version)
for !done {
ev, err := input.ReadOne()
if err != nil {