mirror of
https://github.com/coollabsio/coolify-cli.git
synced 2026-06-19 07:35:04 +00:00
5e2b3d08db
Refactor `coolify docs llms` to emit two AI-oriented artifacts: - `llms.txt` as a concise operating guide - `llms-full.txt` as the exhaustive command and flag catalog Update tests to cover quick/full generation, document both files in README, and adjust CI to fail when either generated file is out of date.
76 lines
1.7 KiB
YAML
76 lines
1.7 KiB
YAML
name: Testing CLI
|
|
|
|
on:
|
|
push:
|
|
branches: ["v4.x"]
|
|
pull_request:
|
|
|
|
jobs:
|
|
lint:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v5
|
|
|
|
- name: Run gofmt
|
|
run: diff -u <(echo -n) <(gofmt -d -s .)
|
|
|
|
- name: Run golangci-lint
|
|
uses: golangci/golangci-lint-action@v8
|
|
with:
|
|
version: v2.5.0 # pin version for consistency
|
|
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v5
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version-file: 'go.mod'
|
|
|
|
- name: Run tests
|
|
run: go test -v -race -cover ./...
|
|
|
|
llms-txt:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v5
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version-file: 'go.mod'
|
|
|
|
- name: Regenerate llms.txt
|
|
run: go run ./coolify docs llms
|
|
|
|
- name: Check uncommitted changes
|
|
run: git diff --exit-code llms.txt llms-full.txt
|
|
|
|
- if: failure()
|
|
run: echo "::error::llms.txt or llms-full.txt is out of date. Run 'go run ./coolify docs llms' and commit the changes."
|
|
|
|
go-mod-tidy:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v5
|
|
|
|
- name: Set up Go
|
|
uses: actions/setup-go@v5
|
|
with:
|
|
go-version-file: 'go.mod'
|
|
|
|
- name: Run go mod tidy
|
|
run: go mod tidy
|
|
|
|
- name: Check uncommitted changes
|
|
run: git diff --exit-code
|
|
|
|
- if: failure()
|
|
run: echo "::error::Check failed, please run 'go mod tidy' and commit the changes."
|