v0.13.3 repo ref, dep and readme udpate
test / test (push) Canceled after 0s

This commit is contained in:
lixen committed 2026-10-04 04:11:43 -04:00
1 parent 6e8d80c788
commit a9fac0f8ab
44 files changed
+104 -109

No files matched your search

+1 -1
View File
@@ -1,6 +1,6 @@
BSD 3-Clause License BSD 3-Clause License
Copyright (c) 2025, Lixen Wraith Copyright (c) 2026, Lixen Wraith
Redistribution and use in source and binary forms, with or without Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met: modification, are permitted provided that the following conditions are met:
+8 -13
View File
@@ -1,14 +1,8 @@
<table> <h1 align="center">♚♛♜♝♞</h1>
<tr> <p align="center">
<td> <a href="https://golang.org"><img src="https://img.shields.io/badge/Go-1.27-00ADD8?style=flat&logo=go" alt="Go 1.27"></a>
<h1>♚♛♜♝♞</h1> <a href="https://opensource.org/licenses/BSD-3-Clause"><img src="https://img.shields.io/badge/License-BSD_3--Clause-blue.svg" alt="License BSD-3"></a>
<p> </p>
<a href="https://golang.org"><img src="https://img.shields.io/badge/Go-1.27-00ADD8?style=flat&logo=go" alt="Go 1.27"></a>
<a href="https://opensource.org/licenses/BSD-3-Clause"><img src="https://img.shields.io/badge/License-BSD_3--Clause-blue.svg" alt="License BSD-3"></a>
</p>
</td>
</tr>
</table>
# Chess # Chess
@@ -169,8 +163,9 @@ The chess server includes an embedded web UI for playing games through a browser
``` ```
### Features ### Features
- Visual chess board with drag-and-drop moves
- Human vs Computer gameplay - Visual chess board with click-to-move and a promotion picker
- Human vs Computer gameplay, with undo, draw offers and resignation
- Configurable engine strength (0-20) - Configurable engine strength (0-20)
- UCI move history with move numbers - UCI move history with move numbers
- FEN display and custom starting positions - FEN display and custom starting positions
+1 -1
View File
@@ -3,7 +3,7 @@
package main package main
import ( import (
"chess/internal/client/display" "github.com/lixenwraith/chess/internal/client/display"
) )
func handleExit() (restart bool) { func handleExit() (restart bool) {
+1 -1
View File
@@ -3,7 +3,7 @@
package main package main
import ( import (
"chess/internal/client/display" "github.com/lixenwraith/chess/internal/client/display"
) )
func handleExit() (restart bool) { func handleExit() (restart bool) {
+4 -4
View File
@@ -7,10 +7,10 @@ import (
"os" "os"
"strings" "strings"
"chess/internal/client/api" "github.com/lixenwraith/chess/internal/client/api"
"chess/internal/client/command" "github.com/lixenwraith/chess/internal/client/command"
"chess/internal/client/display" "github.com/lixenwraith/chess/internal/client/display"
"chess/internal/client/session" "github.com/lixenwraith/chess/internal/client/session"
) )
func main() { func main() {
+2 -2
View File
@@ -11,8 +11,8 @@ import (
"text/tabwriter" "text/tabwriter"
"time" "time"
"chess/internal/server/replay" "github.com/lixenwraith/chess/internal/server/replay"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/lixenwraith/auth" "github.com/lixenwraith/auth"
+6 -6
View File
@@ -14,12 +14,12 @@ import (
"syscall" "syscall"
"time" "time"
"chess/cmd/chess-server/cli" "github.com/lixenwraith/chess/cmd/chess-server/cli"
"chess/internal/server/http" "github.com/lixenwraith/chess/internal/server/http"
"chess/internal/server/processor" "github.com/lixenwraith/chess/internal/server/processor"
"chess/internal/server/service" "github.com/lixenwraith/chess/internal/server/service"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
"chess/internal/server/webserver" "github.com/lixenwraith/chess/internal/server/webserver"
) )
const ( const (
+2 -2
View File
@@ -1,4 +1,4 @@
module chess module github.com/lixenwraith/chess
go 1.27.1 go 1.27.1
@@ -7,7 +7,7 @@ require (
github.com/gofiber/fiber/v2 v2.52.15 github.com/gofiber/fiber/v2 v2.52.15
github.com/google/uuid v1.6.0 github.com/google/uuid v1.6.0
github.com/jackc/pgx/v5 v5.11.0 github.com/jackc/pgx/v5 v5.11.0
github.com/lixenwraith/auth v0.0.0-20260927004242-3b8d4a2946f1 github.com/lixenwraith/auth v0.5.1
golang.org/x/term v0.46.0 golang.org/x/term v0.46.0
) )
+2 -2
View File
@@ -31,8 +31,8 @@ github.com/klauspost/compress v1.20.1 h1:T7kKElXUMXrUJ2E9QhQhxFtcK5rPyLdsGZvdbLM
github.com/klauspost/compress v1.20.1/go.mod h1:LUdAzn7YLVvxLpc7y3V1m40wESHTgc1422pwwBSKYuI= github.com/klauspost/compress v1.20.1/go.mod h1:LUdAzn7YLVvxLpc7y3V1m40wESHTgc1422pwwBSKYuI=
github.com/leodido/go-urn v1.5.0 h1:pLqT2kq1zpHW/1D18QMjMpdtX7cekxqtJJjg5ANyWw0= github.com/leodido/go-urn v1.5.0 h1:pLqT2kq1zpHW/1D18QMjMpdtX7cekxqtJJjg5ANyWw0=
github.com/leodido/go-urn v1.5.0/go.mod h1:9BORnCDhdPBJNDEX+w1bJisa8yOKYi116VeO96s4ifE= github.com/leodido/go-urn v1.5.0/go.mod h1:9BORnCDhdPBJNDEX+w1bJisa8yOKYi116VeO96s4ifE=
github.com/lixenwraith/auth v0.0.0-20260927004242-3b8d4a2946f1 h1:pXqSd6vdTuTh4lYdSmsoCpAJohZYAatZguE835Ru4NU= github.com/lixenwraith/auth v0.5.1 h1:5/eKRyEO4af/vpSLsUgAXaFiECNbCKtQ0EEXnO/oPF4=
github.com/lixenwraith/auth v0.0.0-20260927004242-3b8d4a2946f1/go.mod h1:411JUqnbQgy9jgoFV+fH91TfVUEfzYA4dyPv7f4c264= github.com/lixenwraith/auth v0.5.1/go.mod h1:411JUqnbQgy9jgoFV+fH91TfVUEfzYA4dyPv7f4c264=
github.com/mattn/go-colorable v0.1.15 h1:+u9SLTRGnXv73cEsnsmoZBom+dMU88B2M0aDcWy0/jY= github.com/mattn/go-colorable v0.1.15 h1:+u9SLTRGnXv73cEsnsmoZBom+dMU88B2M0aDcWy0/jY=
github.com/mattn/go-colorable v0.1.15/go.mod h1:6LmQG8QLFO4G5z1gPvYEzlUgJ2wF+stgPZH1UqBm1s8= github.com/mattn/go-colorable v0.1.15/go.mod h1:6LmQG8QLFO4G5z1gPvYEzlUgJ2wF+stgPZH1UqBm1s8=
github.com/mattn/go-isatty v0.0.24 h1:tGZZoVgT/KiqK1c8ocVLeDS8BSWMRd47J3Lbz7vsReI= github.com/mattn/go-isatty v0.0.24 h1:tGZZoVgT/KiqK1c8ocVLeDS8BSWMRd47J3Lbz7vsReI=
+1 -1
View File
@@ -10,7 +10,7 @@ import (
"strings" "strings"
"time" "time"
"chess/internal/client/display" "github.com/lixenwraith/chess/internal/client/display"
) )
const HttpTimeout = 30 * time.Second const HttpTimeout = 30 * time.Second
+3 -3
View File
@@ -6,9 +6,9 @@ import (
"os" "os"
"strings" "strings"
"chess/internal/client/api" "github.com/lixenwraith/chess/internal/client/api"
"chess/internal/client/display" "github.com/lixenwraith/chess/internal/client/display"
"chess/internal/client/session" "github.com/lixenwraith/chess/internal/client/session"
) )
func (r *Registry) registerAuthCommands() { func (r *Registry) registerAuthCommands() {
+3 -3
View File
@@ -5,9 +5,9 @@ import (
"strings" "strings"
"time" "time"
"chess/internal/client/api" "github.com/lixenwraith/chess/internal/client/api"
"chess/internal/client/display" "github.com/lixenwraith/chess/internal/client/display"
"chess/internal/client/session" "github.com/lixenwraith/chess/internal/client/session"
) )
func (r *Registry) registerDebugCommands() { func (r *Registry) registerDebugCommands() {
+3 -3
View File
@@ -7,9 +7,9 @@ import (
"strconv" "strconv"
"strings" "strings"
"chess/internal/client/api" "github.com/lixenwraith/chess/internal/client/api"
"chess/internal/client/display" "github.com/lixenwraith/chess/internal/client/display"
"chess/internal/client/session" "github.com/lixenwraith/chess/internal/client/session"
) )
func (r *Registry) registerGameCommands() { func (r *Registry) registerGameCommands() {
+1 -1
View File
@@ -8,7 +8,7 @@ import (
"os" "os"
"strings" "strings"
"chess/internal/client/display" "github.com/lixenwraith/chess/internal/client/display"
) )
func readPassword(prompt string) (string, error) { func readPassword(prompt string) (string, error) {
+3 -3
View File
@@ -4,9 +4,9 @@ import (
"fmt" "fmt"
"strings" "strings"
"chess/internal/client/api" "github.com/lixenwraith/chess/internal/client/api"
"chess/internal/client/display" "github.com/lixenwraith/chess/internal/client/display"
"chess/internal/client/session" "github.com/lixenwraith/chess/internal/client/session"
) )
// Command defines a client command with its handler // Command defines a client command with its handler
+1 -1
View File
@@ -1,7 +1,7 @@
package session package session
import ( import (
"chess/internal/client/api" "github.com/lixenwraith/chess/internal/client/api"
) )
// Session maintains client state and configuration // Session maintains client state and configuration
+2 -2
View File
@@ -4,8 +4,8 @@ import (
"fmt" "fmt"
"time" "time"
"chess/internal/server/chess" "github.com/lixenwraith/chess/internal/server/chess"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
) )
type Snapshot struct { type Snapshot struct {
+2 -2
View File
@@ -8,8 +8,8 @@ import (
"time" "time"
"unicode" "unicode"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/service" "github.com/lixenwraith/chess/internal/server/service"
"github.com/gofiber/fiber/v2" "github.com/gofiber/fiber/v2"
) )
+3 -3
View File
@@ -9,9 +9,9 @@ import (
"strings" "strings"
"time" "time"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/processor" "github.com/lixenwraith/chess/internal/server/processor"
"chess/internal/server/service" "github.com/lixenwraith/chess/internal/server/service"
"github.com/gofiber/fiber/v2" "github.com/gofiber/fiber/v2"
"github.com/gofiber/fiber/v2/middleware/cors" "github.com/gofiber/fiber/v2/middleware/cors"
+5 -5
View File
@@ -8,11 +8,11 @@ import (
"testing" "testing"
"time" "time"
"chess/internal/server/chess" "github.com/lixenwraith/chess/internal/server/chess"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/service" "github.com/lixenwraith/chess/internal/server/service"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
"chess/internal/server/storage/pgtest" "github.com/lixenwraith/chess/internal/server/storage/pgtest"
"github.com/gofiber/fiber/v2" "github.com/gofiber/fiber/v2"
"github.com/google/uuid" "github.com/google/uuid"
+2 -2
View File
@@ -3,8 +3,8 @@ package http
import ( import (
"errors" "errors"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/service" "github.com/lixenwraith/chess/internal/server/service"
"github.com/gofiber/fiber/v2" "github.com/gofiber/fiber/v2"
"github.com/lixenwraith/auth" "github.com/lixenwraith/auth"
+1 -1
View File
@@ -5,7 +5,7 @@ import (
"net/http/httptest" "net/http/httptest"
"testing" "testing"
"chess/internal/server/service" "github.com/lixenwraith/chess/internal/server/service"
"github.com/gofiber/fiber/v2" "github.com/gofiber/fiber/v2"
) )
+1 -1
View File
@@ -5,7 +5,7 @@ import (
"reflect" "reflect"
"strings" "strings"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"github.com/go-playground/validator/v10" "github.com/go-playground/validator/v10"
"github.com/gofiber/fiber/v2" "github.com/gofiber/fiber/v2"
+1 -1
View File
@@ -1,7 +1,7 @@
package processor package processor
import ( import (
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
) )
// CommandType defines the type of command being executed // CommandType defines the type of command being executed
+5 -5
View File
@@ -10,11 +10,11 @@ import (
"time" "time"
"unicode" "unicode"
"chess/internal/server/chess" "github.com/lixenwraith/chess/internal/server/chess"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/engine" "github.com/lixenwraith/chess/internal/server/engine"
"chess/internal/server/game" "github.com/lixenwraith/chess/internal/server/game"
"chess/internal/server/service" "github.com/lixenwraith/chess/internal/server/service"
) )
const ( const (
+2 -2
View File
@@ -7,8 +7,8 @@ import (
"sync" "sync"
"time" "time"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/engine" "github.com/lixenwraith/chess/internal/server/engine"
) )
// EngineTask contains computer move calculation request and response channel // EngineTask contains computer move calculation request and response channel
+1 -1
View File
@@ -6,7 +6,7 @@ import (
"testing" "testing"
"time" "time"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
) )
func TestEngineQueueShutdownCancelsAndWaitsForCallback(t *testing.T) { func TestEngineQueueShutdownCancelsAndWaitsForCallback(t *testing.T) {
+3 -3
View File
@@ -4,9 +4,9 @@ import (
"errors" "errors"
"testing" "testing"
"chess/internal/server/chess" "github.com/lixenwraith/chess/internal/server/chess"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/game" "github.com/lixenwraith/chess/internal/server/game"
) )
func TestRulesCheck(t *testing.T) { func TestRulesCheck(t *testing.T) {
+3 -3
View File
@@ -9,9 +9,9 @@ import (
"strconv" "strconv"
"strings" "strings"
"chess/internal/server/chess" "github.com/lixenwraith/chess/internal/server/chess"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
) )
var ( var (
+2 -2
View File
@@ -5,8 +5,8 @@ import (
"testing" "testing"
"time" "time"
"chess/internal/server/chess" "github.com/lixenwraith/chess/internal/server/chess"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
) )
// stored returns the stored form of a line played from start. // stored returns the stored form of a line played from start.
+3 -3
View File
@@ -3,9 +3,9 @@ package replay
import ( import (
"fmt" "fmt"
"chess/internal/server/chess" "github.com/lixenwraith/chess/internal/server/chess"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
) )
// Verify checks a stored game against the rules and returns one line per // Verify checks a stored game against the rules and returns one line per
+2 -2
View File
@@ -6,8 +6,8 @@ import (
"testing" "testing"
"time" "time"
"chess/internal/server/chess" "github.com/lixenwraith/chess/internal/server/chess"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"github.com/google/uuid" "github.com/google/uuid"
) )
+3 -3
View File
@@ -6,9 +6,9 @@ import (
"log/slog" "log/slog"
"time" "time"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/game" "github.com/lixenwraith/chess/internal/server/game"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
"github.com/google/uuid" "github.com/google/uuid"
) )
+4 -4
View File
@@ -5,10 +5,10 @@ import (
"testing" "testing"
"time" "time"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/game" "github.com/lixenwraith/chess/internal/server/game"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
"chess/internal/server/storage/pgtest" "github.com/lixenwraith/chess/internal/server/storage/pgtest"
"github.com/google/uuid" "github.com/google/uuid"
) )
+4 -4
View File
@@ -10,10 +10,10 @@ import (
"strings" "strings"
"time" "time"
"chess/internal/server/chess" "github.com/lixenwraith/chess/internal/server/chess"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/replay" "github.com/lixenwraith/chess/internal/server/replay"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
"github.com/google/uuid" "github.com/google/uuid"
) )
+2 -2
View File
@@ -5,8 +5,8 @@ import (
"strings" "strings"
"testing" "testing"
"chess/internal/server/chess" "github.com/lixenwraith/chess/internal/server/chess"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"github.com/google/uuid" "github.com/google/uuid"
) )
+1 -1
View File
@@ -6,7 +6,7 @@ import (
"log/slog" "log/slog"
"time" "time"
"chess/internal/server/replay" "github.com/lixenwraith/chess/internal/server/replay"
"github.com/lixenwraith/auth" "github.com/lixenwraith/auth"
) )
+2 -2
View File
@@ -6,8 +6,8 @@ import (
"testing" "testing"
"time" "time"
"chess/internal/server/chess" "github.com/lixenwraith/chess/internal/server/chess"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/lixenwraith/auth" "github.com/lixenwraith/auth"
+3 -3
View File
@@ -9,9 +9,9 @@ import (
"sync/atomic" "sync/atomic"
"time" "time"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"chess/internal/server/game" "github.com/lixenwraith/chess/internal/server/game"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
"github.com/lixenwraith/auth" "github.com/lixenwraith/auth"
) )
+1 -1
View File
@@ -9,7 +9,7 @@ import (
"sync" "sync"
"time" "time"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/lixenwraith/auth" "github.com/lixenwraith/auth"
+1 -1
View File
@@ -5,7 +5,7 @@ import (
"testing" "testing"
"time" "time"
"chess/internal/server/storage" "github.com/lixenwraith/chess/internal/server/storage"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/lixenwraith/auth" "github.com/lixenwraith/auth"
+1 -1
View File
@@ -1,7 +1,7 @@
package service package service
import ( import (
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
"context" "context"
"fmt" "fmt"
"sync" "sync"
+1 -1
View File
@@ -6,7 +6,7 @@ import (
"testing" "testing"
"time" "time"
"chess/internal/server/core" "github.com/lixenwraith/chess/internal/server/core"
) )
func TestWaitRegistryDeliversNotificationToCallerAndRemovesWaiter(t *testing.T) { func TestWaitRegistryDeliversNotificationToCallerAndRemovesWaiter(t *testing.T) {
+1 -1
View File
@@ -11,7 +11,7 @@ import (
"testing" "testing"
"time" "time"
"chess/internal/server/storage/pgtest" "github.com/lixenwraith/chess/internal/server/storage/pgtest"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/jackc/pgx/v5/pgconn" "github.com/jackc/pgx/v5/pgconn"