Compare commits

..

2 Commits

Author SHA1 Message Date
Icedream b733ed5159
Merge a20d0e6662 into a6481c8847 2024-05-05 07:41:04 +00:00
Icedream a20d0e6662
Rewrite and update the code for the modern world. 2024-05-05 09:39:54 +02:00
6 changed files with 12 additions and 9 deletions

View File

@ -9,14 +9,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Set up Go 1.22
- name: Set up Go 1.21
uses: actions/setup-go@v5
with:
go-version: 1.22
go-version: 1.21
id: go
- name: Check out code into the Go module directory
uses: actions/checkout@v4
- name: Build icecon binary
run: go build -v ./cmd/icecon
- name: Build
run: go build -v .

View File

@ -98,8 +98,10 @@ func main() {
}
// Which UI should be run?
log.Println("Starting user interface.")
if err := ui.Run(rconClient, wantGui); err != nil {
log.Fatal("User interface failed:", err)
return
}
log.Println("Done.")
}

View File

@ -3,6 +3,8 @@ package ui
import (
"errors"
"fmt"
"log"
"reflect"
"slices"
"github.com/icedream/icecon/internal/rcon"
@ -57,6 +59,7 @@ func Run(rconClient *rcon.Client, wantGraphical bool) error {
if err != nil {
return fmt.Errorf("failed to instantiate user interface: %w", err)
}
log.Println("Found user interface:", reflect.TypeOf(ui))
return ui.Run()
}
return ErrNotSupported

View File

@ -1,8 +1,7 @@
// This file was created by ui2walk and may be regenerated.
// DO NOT EDIT OR YOUR MODIFICATIONS WILL BE LOST!
//go:build windows
// +build windows
//+build windows
package windows

View File

@ -1,8 +1,7 @@
// This file was created by ui2walk and may be regenerated.
// DO NOT EDIT OR YOUR MODIFICATIONS WILL BE LOST!
//go:build windows
// +build windows
//+build windows
package windows

View File

@ -1,3 +1,3 @@
package windows
//go:generate go run -mod=mod github.com/icedream/ui2walk -pkg $GOPACKAGE
//go:generate go run -mod=mod github.com/icedream/ui2walk