Skip to content

Commit 138f7e4

Browse files
authored
chore: deploy-audit cleanup — drop fictional deploy.sh, fix CHANGELOG, add release workflow (#56)
A deploy-readiness audit surfaced four stale/incorrect items in this repo; this commit removes or repairs each. Removed ------- - scripts/deploy.sh — referenced a Dockerfile, a deployments/kubernetes/ manifest, an internal/integration/ test package, and a k6 load-test script that never existed. tok is a Go library (AGENTS.md, .goreleaser.yml builds.skip: true); deployment is `go get`. - /tokd entry in .gitignore — the ./server HTTP daemon never shipped. Fixed ----- - CHANGELOG.md: * 0.1.0 heading moved below [Unreleased] (Keep-a-Changelog ordering). * Stripped the backwards `compare/v1.1.0...0.1.0` diff link. * Stopped claiming we re-baselined `.release-please-manifest.json` and `scripts/install.sh` — neither file exists in this repo. * "HTTP server mode (tokd)" entry now documents that the daemon did not ship, matching the existing historical note under [0.29.0]. - .github/workflows/ci.yml: pin gosec to v2.22.4 (was v2.21.4), matching every other gosec invocation in the workflow + sibling repos. Added ----- - .github/workflows/release.yml: trigger goreleaser on `v*` tag pushes. The existing .goreleaser.yml builds source archives + SHA-256 checksums + SPDX SBOM (`builds.skip: true`) but had no workflow to invoke it. Validation ---------- - go build ./... — clean - go vet ./... — clean - gofumpt -l . — clean - goimports -l . — clean - golangci-lint run --timeout=5m — 0 issues - go test ./... -short — all pass - govulncheck ./... — no vulnerabilities
1 parent 68f3357 commit 138f7e4

5 files changed

Lines changed: 58 additions & 322 deletions

File tree

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ jobs:
136136
- name: gosec (advisory)
137137
continue-on-error: true
138138
run: |
139-
go install github.com/securego/gosec/v2/cmd/gosec@v2.21.4
139+
go install github.com/securego/gosec/v2/cmd/gosec@v2.22.4
140140
gosec -exclude=G104,G301,G302,G304,G306 ./...
141141
142142
# -------------------------------------------------------------------------

.github/workflows/release.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Release workflow for tok — Go LIBRARY.
2+
#
3+
# tok ships as a Go module (no binary). This workflow runs on a `v*` tag and
4+
# publishes a source archive, SHA-256 checksums, and an SBOM via goreleaser
5+
# (config: .goreleaser.yml — `builds.skip: true`, `source.enabled: true`).
6+
# Consumers depend on the tag via `go get github.com/GrayCodeAI/tok@vX.Y.Z`.
7+
8+
name: release
9+
10+
on:
11+
push:
12+
tags: ["v*"]
13+
14+
permissions:
15+
contents: write # create GitHub Release + upload assets
16+
id-token: write # reserved for keyless cosign signing later
17+
18+
jobs:
19+
goreleaser:
20+
runs-on: ubuntu-latest
21+
steps:
22+
- name: Checkout
23+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
24+
with:
25+
fetch-depth: 0 # goreleaser needs full history for changelog
26+
27+
- name: Set up Go
28+
uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
29+
with:
30+
go-version: "1.26.4"
31+
cache: true
32+
33+
- name: Run GoReleaser
34+
uses: goreleaser/goreleaser-action@1a80836c5c9d9e5755a25cb59ec6f45a3b5f41a8 # v7.2.1
35+
with:
36+
distribution: goreleaser
37+
version: "v6.3.0"
38+
args: release --clean
39+
env:
40+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ build/
1010
.artifacts/
1111
/cmd # stray compiled binary tok is library-only, no cmd/ package
1212
/tok # local build of any sample binary
13-
/tokd # local build of the optional HTTP server (server/)
1413
*.test # `go test -c` compiled test binaries
1514

1615
# Dev state

CHANGELOG.md

Lines changed: 17 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -7,23 +7,25 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
> **tok is a Go library**, not a CLI. Install with
99
> `go get github.com/GrayCodeAI/tok` and import `github.com/GrayCodeAI/tok`.
10-
> An optional HTTP server (`tokd`) lives in `./server`
11-
> (`go run ./server -addr 127.0.0.1:8080`). CLI-style verbs such as
12-
> `tok compress` are exposed by [Hawk](https://github.com/GrayCodeAI/hawk),
13-
> which embeds this library. Older entries below mentioning CLI commands, shell
14-
> hooks, agent installers, or a TUI describe prototype work that did not ship in
10+
> CLI-style verbs such as `tok compress` are exposed by
11+
> [Hawk](https://github.com/GrayCodeAI/hawk), which embeds this library.
12+
> Older entries below mentioning CLI commands, shell hooks, agent installers,
13+
> a TUI, or an HTTP `tokd` server describe prototype work that did not ship in
1514
> the library; see the historical note under `[0.29.0]`.
1615
17-
## [0.1.0](https://github.com/GrayCodeAI/tok/compare/v1.1.0...0.1.0) (2026-06-08)
16+
## [Unreleased]
1817

1918
### Changed
20-
- **Version re-baselined to `0.1.0`** across `.release-please-manifest.json`,
21-
`CITATION.cff`, and `scripts/install.sh`, aligning tok with the rest of the
22-
hawk-eco ecosystem (`hawk`, `eyrie`, `yaad`, `sight`, `inspect`).
19+
- **Version re-baselined to `0.1.0`** across `CITATION.cff` and the embedded
20+
`Version` constant, aligning tok with the rest of the hawk-eco ecosystem
21+
(`hawk`, `eyrie`, `yaad`, `sight`, `inspect`). No git tag has been cut yet.
2322

24-
## [Unreleased]
23+
### Removed
24+
- `scripts/deploy.sh` — referenced a Dockerfile, k8s manifests, and an
25+
`internal/integration/` package that never existed. tok is a Go library
26+
(no binary, no HTTP server); deployment happens via `go get`.
2527

26-
See [0.1.0] for the latest changes.
28+
## [0.1.0] (unreleased)
2729

2830
### Added
2931
- **Custom filter DSL** — define regex find/replace rules in a TOML file
@@ -41,9 +43,10 @@ See [0.1.0] for the latest changes.
4143
tokens first via a pluggable `PerplexityScorer` (zero-dependency heuristic
4244
default; experimental `OllamaScorer` available with `-tags experimental_ollama`).
4345
Opt-in.
44-
- **HTTP server mode (`tokd`)** — optional standalone server exposing
45-
`POST /compress`, `POST /estimate`, and `GET /health` over HTTP for
46-
cloud/agent use; the core library stays import-clean.
46+
- **HTTP server mode (`tokd`)**_removed before release_. Earlier work
47+
on a standalone HTTP server lived in `./server` but did not ship; the
48+
core library exposes no HTTP surface. See the historical note in
49+
`[0.29.0]` for context.
4750
- **Compression-quality benchmark harness** (`benchmarks/quality`) — offline
4851
harness reporting compression ratio, char retention, and a ROUGE-1
4952
lexical-fidelity proxy against an LLMLingua-style baseline arm.

0 commit comments

Comments
 (0)