Skip to content

Comments

feat: add kt version command#8

Merged
kostyay merged 1 commit intomainfrom
feat/kt-version
Feb 12, 2026
Merged

feat: add kt version command#8
kostyay merged 1 commit intomainfrom
feat/kt-version

Conversation

@kostyay
Copy link
Owner

@kostyay kostyay commented Feb 12, 2026

Summary

  • Add kt version command that prints version, commit SHA, and build date
  • Version info injected at build time via -ldflags in Makefile using git describe --tags
  • Falls back to "dev" when built without ldflags (plain go build)
  • Supports --json flag for machine-readable output

Test plan

  • make lint passes
  • make test passes
  • make build && ./kt version shows injected version
  • ./kt version --json outputs valid JSON

🤖 Generated with Claude Code

Version, commit SHA, and build date injected via ldflags in Makefile.
Falls back to "dev" for plain go build.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@kostyay kostyay merged commit 7bbafb1 into main Feb 12, 2026
3 checks passed
@kostyay kostyay deleted the feat/kt-version branch February 12, 2026 14:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant