mirror of https://github.com/icedream/icecon.git
Compare commits
2 Commits
21ece04fa4
...
b733ed5159
Author | SHA1 | Date |
---|---|---|
|
b733ed5159 | |
|
a20d0e6662 |
|
@ -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 .
|
||||
|
|
|
@ -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.")
|
||||
}
|
||||
|
|
|
@ -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
|
||||
|
|
|
@ -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
|
||||
|
||||
|
|
|
@ -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
|
||||
|
||||
|
|
|
@ -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
|
||||
|
|
Loading…
Reference in New Issue