Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ task build-binary # cd cli && go build -> ./cli/dockem
task test # cd cli && go test -count=1 ./...
task test-verbose # same, with -v
task build # cross-compile release binaries into ./release (run from main; uses `git describe --tags HEAD`)
task release # entro-version release develop -> main (git flow); `task release-major` for a major bump
task release # brrelease release develop -> main (git flow); `task release-major` for a major bump
```

Run a single test:
Expand Down Expand Up @@ -88,7 +88,7 @@ This applies to the **classic path only**. `TarBuildContext` handles a `--docker

- Human-readable output goes through `LogInfo`/`LogWarn`/`LogError` in `cli/utils/log.go` (all writing to `os.Stderr`) rather than raw `fmt.Printf`/`fmt.Print`/`fmt.Println`. Errors are surfaced by calling `LogError` with a sentence explaining what the user should check (`LogWarn`/`LogError` prepend the `WARN: ` / `ERROR: ` prefix themselves), then returning the raw error up to `cmd/build.go`, which panics. Match this style rather than wrapping errors.
- One exported function per file in `utils/`, file named in snake_case after the function.
- Commits follow Conventional Commits — the CHANGELOG is generated by `commit-and-tag-version` via `entro-version`, and scopes like `feat(auth):` / `fix(auth):` with a trailing `#issue` reference are the norm.
- Git flow: work lands on `develop`, releases merge to `main` and tag. `package.json` at the root exists only to hold the version that the release tooling bumps.
- Commits follow Conventional Commits — the CHANGELOG is generated by `commit-and-tag-version` via [`brrelease`](https://github.com/kerren/brrelease), and scopes like `feat(auth):` / `fix(auth):` with a trailing `#issue` reference are the norm.
- Git flow: work lands on `develop`, releases merge to `main` and tag. `package.json` at the root exists only to hold the version that the release tooling bumps. `brrelease` is not published on npm, so it cannot be run through `npx` — the release tasks call it off the `PATH` and check for it first (`brew install kerren/brrelease-tap/brrelease`, or a tarball from its releases page). It runs on the branch you are on, so `task release` must be run from `develop`: `--merge-into-branch=main` merges the release into `main` and back into `develop`, and `--auto-push` pushes both branches and the tag.
- The release binary's `--version` comes from `-ldflags "-X dockem/cmd.Version=$version"`; `cmd.Version` defaults to `dev-build` in local builds.
- The README documents every flag and concept; update it alongside any flag change in `cli/cmd/build.go`.
10 changes: 8 additions & 2 deletions taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,19 @@ tasks:

release:
desc: "Run a standard release from develop to main using git flow"
preconditions:
- sh: command -v brrelease
msg: "brrelease is not installed. Install it with: brew install kerren/brrelease-tap/brrelease"
cmds:
- npx --yes entro-version release --main-branch-name=main
- brrelease release --merge-into-branch=main --auto-push

release-major:
desc: "Run a major release from develop to main using git flow"
preconditions:
- sh: command -v brrelease
msg: "brrelease is not installed. Install it with: brew install kerren/brrelease-tap/brrelease"
cmds:
- npx --yes entro-version release --main-branch-name=main --commit-and-tag-version-flag="--release-as=major"
- brrelease release --merge-into-branch=main --release-as=major --auto-push

build:
desc: "Build the binary - the assumption is that this is done from the main branch"
Expand Down
Loading