feat: initial Netts energy orchestrator

This commit is contained in:
你的用户名
2025-11-03 19:26:48 +08:00
commit 891c32e288
25 changed files with 2210 additions and 0 deletions

43
.github/workflows/ci.yaml vendored Normal file
View File

@@ -0,0 +1,43 @@
name: CI
on:
push:
branches: [ main, master ]
pull_request:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: "1.24"
- name: Go module cache
uses: actions/cache@v4
with:
path: |
~/go/pkg/mod
~/.cache/go-build
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Check formatting
run: |
gofmt -l . | tee /tmp/gofmt.txt
if [ -s /tmp/gofmt.txt ]; then
echo "The following files need gofmt:"
cat /tmp/gofmt.txt
exit 1
fi
- name: Go vet
run: go vet ./...
- name: Run tests
run: go test ./...