From 77356465c475a496de0e3e2e03410cf2544e6f29 Mon Sep 17 00:00:00 2001 From: disk0dancer Date: Fri, 17 Apr 2026 16:55:40 +0300 Subject: [PATCH 1/4] Add optional fields to SKILL.md per agentskills spec --- skills/climate-generator/SKILL.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/skills/climate-generator/SKILL.md b/skills/climate-generator/SKILL.md index 1284680..58d20e5 100644 --- a/skills/climate-generator/SKILL.md +++ b/skills/climate-generator/SKILL.md @@ -3,6 +3,11 @@ name: climate-generator description: > Generate Go CLIs from OpenAPI 3.x specs with climate, inspect generated CLIs, and emit Markdown skill prompts so those CLIs can be attached to agent workflows. +license: Apache-2.0 +compatibility: Requires Go 1.21+ and climate CLI (brew install disk0Dancer/tap/climate) +metadata: + author: disk0Dancer + version: "1.0" --- # Skill: climate-generator From 92b81228df1c1cf93c1e417e04be72f37279aec0 Mon Sep 17 00:00:00 2001 From: disk0dancer Date: Fri, 17 Apr 2026 16:57:02 +0300 Subject: [PATCH 2/4] Sync .agents/skills with skills/ for Copilot compat --- .agents/skills/climate-generator/SKILL.md | 122 ++++++++++++++++++++++ 1 file changed, 122 insertions(+) create mode 100644 .agents/skills/climate-generator/SKILL.md diff --git a/.agents/skills/climate-generator/SKILL.md b/.agents/skills/climate-generator/SKILL.md new file mode 100644 index 0000000..58d20e5 --- /dev/null +++ b/.agents/skills/climate-generator/SKILL.md @@ -0,0 +1,122 @@ +--- +name: climate-generator +description: > + Generate Go CLIs from OpenAPI 3.x specs with climate, inspect generated CLIs, + and emit Markdown skill prompts so those CLIs can be attached to agent workflows. +license: Apache-2.0 +compatibility: Requires Go 1.21+ and climate CLI (brew install disk0Dancer/tap/climate) +metadata: + author: disk0Dancer + version: "1.0" +--- + +# Skill: climate-generator + +You have access to `climate`, a CLI that generates production-ready Go command-line +clients from OpenAPI specifications and can emit Markdown prompts for agent skills. + +## When to use this skill + +- The user has an OpenAPI 3.x URL or file and wants a CLI quickly. +- The user wants a human-usable API client rather than writing SDK glue code. +- The user wants to turn a generated CLI into a reusable agent skill. +- The user wants to list, remove, or upgrade a previously generated CLI. + +## Core workflow + +1. Generate a CLI from the provided spec. +2. Capture the resulting `cli_name`, `binary_path`, and `source_dir`. +3. If the user wants agent integration, run `climate skill generate `. +4. If the user wants the CLI managed on GitHub, run `climate publish `. +5. Follow the generated instructions from that Markdown prompt. + +## Commands + +### Generate a CLI + +```bash +climate generate [--name ] [--out-dir ] [--no-build] [--force] +``` + +- `` can be a local path or an HTTP(S) URL. +- `--no-build` generates source only. +- `--force` overwrites an existing output directory. + +Success output is JSON: + +```json +{ + "cli_name": "", + "binary_path": "", + "source_dir": "", + "version": "", + "openapi_hash": "" +} +``` + +### List generated CLIs + +```bash +climate list +``` + +### Remove a generated CLI + +```bash +climate remove [--purge-sources] +``` + +### Upgrade a generated CLI + +```bash +climate upgrade [--openapi ] +``` + +### Generate a skill prompt for a CLI + +```bash +climate skill generate [--mode=full|compact] [--out ] +``` + +### Publish a generated CLI to GitHub + +```bash +climate publish [--owner ] [--repo ] [--visibility public|private] [--github-token ] +``` + +This command creates or reuses a GitHub repository through the GitHub API, +writes lifecycle files, initializes git, and pushes the generated source tree. + +### Print the built-in climate skill + +```bash +climate skill generator +``` + +## Typical examples + +Generate a CLI: + +```bash +climate generate --name petstore https://petstore3.swagger.io/api/v3/openapi.json +``` + +Generate a compact skill prompt for that CLI: + +```bash +climate skill generate petstore --mode=compact +``` + +Publish it to GitHub: + +```bash +climate publish petstore --owner disk0Dancer +``` + +## Notes + +- All climate output is JSON on success. +- Errors are emitted as structured JSON on stderr. +- Generated CLIs follow the shape ` [flags] --output=json|table|raw`. +- Homebrew install is available via `brew tap disk0Dancer/tap && brew install climate`. +- GitHub publish auth is read from `--github-token`, `GITHUB_TOKEN`, or `GH_TOKEN`. From 0d7c5314bac93cd3df00e598fd3597772478f8ac Mon Sep 17 00:00:00 2001 From: disk0dancer Date: Fri, 17 Apr 2026 17:04:16 +0300 Subject: [PATCH 3/4] Remove .agents/skills from git, add to gitignore per gh skill --- .agents/skills/climate-generator/SKILL.md | 122 ---------------------- .gitignore | 2 + 2 files changed, 2 insertions(+), 122 deletions(-) delete mode 100644 .agents/skills/climate-generator/SKILL.md diff --git a/.agents/skills/climate-generator/SKILL.md b/.agents/skills/climate-generator/SKILL.md deleted file mode 100644 index 58d20e5..0000000 --- a/.agents/skills/climate-generator/SKILL.md +++ /dev/null @@ -1,122 +0,0 @@ ---- -name: climate-generator -description: > - Generate Go CLIs from OpenAPI 3.x specs with climate, inspect generated CLIs, - and emit Markdown skill prompts so those CLIs can be attached to agent workflows. -license: Apache-2.0 -compatibility: Requires Go 1.21+ and climate CLI (brew install disk0Dancer/tap/climate) -metadata: - author: disk0Dancer - version: "1.0" ---- - -# Skill: climate-generator - -You have access to `climate`, a CLI that generates production-ready Go command-line -clients from OpenAPI specifications and can emit Markdown prompts for agent skills. - -## When to use this skill - -- The user has an OpenAPI 3.x URL or file and wants a CLI quickly. -- The user wants a human-usable API client rather than writing SDK glue code. -- The user wants to turn a generated CLI into a reusable agent skill. -- The user wants to list, remove, or upgrade a previously generated CLI. - -## Core workflow - -1. Generate a CLI from the provided spec. -2. Capture the resulting `cli_name`, `binary_path`, and `source_dir`. -3. If the user wants agent integration, run `climate skill generate `. -4. If the user wants the CLI managed on GitHub, run `climate publish `. -5. Follow the generated instructions from that Markdown prompt. - -## Commands - -### Generate a CLI - -```bash -climate generate [--name ] [--out-dir ] [--no-build] [--force] -``` - -- `` can be a local path or an HTTP(S) URL. -- `--no-build` generates source only. -- `--force` overwrites an existing output directory. - -Success output is JSON: - -```json -{ - "cli_name": "", - "binary_path": "", - "source_dir": "", - "version": "", - "openapi_hash": "" -} -``` - -### List generated CLIs - -```bash -climate list -``` - -### Remove a generated CLI - -```bash -climate remove [--purge-sources] -``` - -### Upgrade a generated CLI - -```bash -climate upgrade [--openapi ] -``` - -### Generate a skill prompt for a CLI - -```bash -climate skill generate [--mode=full|compact] [--out ] -``` - -### Publish a generated CLI to GitHub - -```bash -climate publish [--owner ] [--repo ] [--visibility public|private] [--github-token ] -``` - -This command creates or reuses a GitHub repository through the GitHub API, -writes lifecycle files, initializes git, and pushes the generated source tree. - -### Print the built-in climate skill - -```bash -climate skill generator -``` - -## Typical examples - -Generate a CLI: - -```bash -climate generate --name petstore https://petstore3.swagger.io/api/v3/openapi.json -``` - -Generate a compact skill prompt for that CLI: - -```bash -climate skill generate petstore --mode=compact -``` - -Publish it to GitHub: - -```bash -climate publish petstore --owner disk0Dancer -``` - -## Notes - -- All climate output is JSON on success. -- Errors are emitted as structured JSON on stderr. -- Generated CLIs follow the shape ` [flags] --output=json|table|raw`. -- Homebrew install is available via `brew tap disk0Dancer/tap && brew install climate`. -- GitHub publish auth is read from `--github-token`, `GITHUB_TOKEN`, or `GH_TOKEN`. diff --git a/.gitignore b/.gitignore index f3e1625..972b6af 100644 --- a/.gitignore +++ b/.gitignore @@ -237,3 +237,5 @@ marimo/_static/ marimo/_lsp/ __marimo__/ .omx/ +.agents/skills/ +.claude/skills/ From 8799810c45e439adace664b0c50c0ab961945596 Mon Sep 17 00:00:00 2001 From: disk0dancer Date: Fri, 17 Apr 2026 17:17:53 +0300 Subject: [PATCH 4/4] Fix CI: add permissions block, use go-version-file --- .github/workflows/ci.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 544ff98..821b632 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,6 +6,9 @@ on: pull_request: branches: [main] +permissions: + contents: read + jobs: test: name: Test @@ -17,7 +20,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v5 with: - go-version: "1.21" + go-version-file: go.mod - name: Cache Go modules uses: actions/cache@v4