Skip to content

Releases: dkmnx/kairo

v1.2.2

Choose a tag to compare

@github-actions github-actions released this 04 Jan 06:21

Fixed

  • Audit errors: Audit logger failures now log to stderr instead of being silently ignored
    • Fixes potential data loss when audit logging fails (permission errors, disk full, etc.)
    • Added logAuditEvent() helper function for centralized error handling
  • Thread safety: Fixed global variable race conditions in concurrent scenarios
    • Added mutex-protected accessors: getVerbose(), setVerbose(), setConfigDir()
    • Updated all production code to use thread-safe accessors for verbose flag reads
    • Updated all tests to use thread-safe accessors for global variable access
    • Added race condition tests in cmd/race_test.go
  • Lock optimization: Reduced lock hold time in getConfigDir() by releasing before env.GetConfigDir()
  • Duplicate binding: Removed duplicate verbose flag binding in cmd/audit.go
    • Persistent flags in cmd/root.go are automatically inherited by all subcommands
  • Flag parsing: Removed redundant manual --config parsing in Execute() function
    • Cobra's persistent flag binding already handles this correctly

Changed

  • Code quality: Removed unused getConfigDirRaw() function (YAGNI)

v1.2.1

Choose a tag to compare

@github-actions github-actions released this 03 Jan 07:24

Fixed

  • Shell completion: Fixed kairo completion fish and other shell completion commands
    • The __complete and __completeNoDesc hidden Cobra commands were being intercepted and treated as provider names
    • Added check in cmd/root.go to allow these completion commands to pass through unchanged
    • Fish completions now properly list all subcommands and providers

Documentation

  • Updated documentation for audit feature and architecture
  • Added docs/guides/audit-guide.md with comprehensive audit log usage documentation
  • Updated cmd/README.md with new command reference, architecture diagrams, and audit integration docs
  • Updated docs/architecture/README.md with audit logging architecture, error handling patterns, and design principles

v1.2.0

Choose a tag to compare

@dkmnx dkmnx released this 02 Jan 10:25

Added

  • Audit logging: New kairo audit command to track all configuration changes
    • kairo audit list - Human-readable list showing timestamp, provider, action, and changes
    • kairo audit export -o file.csv - Export to CSV format with changes column
    • kairo audit export -o file.json -f json - Export to JSON format
    • API keys masked in logs (e.g., sk-an********mnop)
    • Tracks: config, default, reset, rotate, setup, and switch commands

v1.1.1

Choose a tag to compare

@github-actions github-actions released this 02 Jan 07:52

Added

  • Provider shorthand: Use kairo <provider> instead of kairo switch <provider> for quicker provider switching
    • Arguments after provider name are passed through to Claude (e.g., kairo anthropic --help)
    • Unknown provider names now show "not configured" error instead of "unknown command"
    • All existing subcommands remain unaffected

Fixed

  • Race conditions: Fixed test flakiness caused by shared flag state in CLI tests
  • Test pollution: Prevented argument handling from affecting subsequent tests
  • Code formatting: Added auto-formatting to make lint for automatic gofmt fixes before checking
  • Style cleanup: Fixed formatting in root_test.go

v1.1.0

Choose a tag to compare

@github-actions github-actions released this 29 Dec 15:37

Added

  • Provider shorthand: Use kairo <provider> instead of kairo switch <provider> for quicker provider switching
    • Arguments after provider name are passed through to Claude (e.g., kairo anthropic --help)
    • Unknown provider names now show "not configured" error instead of "unknown command"
    • All existing subcommands remain unaffected

v1.0.2

Choose a tag to compare

@github-actions github-actions released this 28 Dec 16:05

Fixed

  • Update command: Fixed checksum file download error by correcting filename construction
    • Script was using version with 'v' prefix (e.g., kairo_v1.0.1_checksums.txt)
    • Actual release asset uses format without prefix (e.g., kairo_1.0.1_checksums.txt)
    • Added version prefix stripping logic to match actual GoReleaser naming
  • Install script: Fixed shellcheck warnings for safer script execution
    • Changed trap command to use single quotes to prevent early variable expansion
    • Fixed PATH export statement for proper variable display

v1.0.1

Choose a tag to compare

@github-actions github-actions released this 28 Dec 15:26

Added

  • Structured error handling: Implemented internal/errors package with typed errors (ConfigError, CryptoError, ValidationError, ProviderError, NetworkError, FileSystemError)
  • Error context: All errors now include structured context and helpful hints for debugging
  • Comprehensive user guides: Added new documentation:
    • Error handling examples (docs/guides/error-handling-examples.md)
    • Advanced configuration scenarios (docs/guides/advanced-configuration.md)
    • Claude Code integration examples (docs/guides/claude-integration-examples.md)
  • Enhanced troubleshooting: Added 7 advanced troubleshooting scenarios to docs/troubleshooting/README.md
  • Setup helper tests: Added tests for prompt functions (promptForProvider, promptForAPIKey, promptForBaseURL)
  • Update command tests: Added tests for getEnvFunc, getLatestRelease, and versionGreaterThan
  • Helper function tests: Added tests for parseIntOrZero, parseProviderSelection, validateCustomProviderName

Changed

  • Internal refactoring: Extracted 8 helper functions from cmd/setup.go for better maintainability:
    • validateCustomProviderName, buildProviderConfig, getSortedSecretsKeys
    • formatSecretsFileContent, saveProviderConfigFile, validateAPIKey, validateBaseURL
  • Improved error messages: All config and crypto errors now use structured types with context
  • Better test coverage: cmd package coverage increased from 35.2% to 40.5%
    • Added tests for edge cases and error paths in update.go
    • Increased coverage for version comparison from 71.4% to 100%
    • Increased coverage for getLatestRelease from 78.9% to 89.5%
  • README improvements: Added usage examples, reorganized documentation section, added Direct Query Mode (--) documentation

Fixed

  • Documentation: Fixed 15 markdownlint errors across new documentation files
  • Error handling tests: internal/errors package coverage improved from 78.1% to 100%

v1.0.0

Choose a tag to compare

@github-actions github-actions released this 27 Dec 18:23

[1.0.0] - 2025-12-28

Added

  • Production-ready release with complete feature set
  • Comprehensive documentation suite (User Guide, Development Guide, Architecture, Troubleshooting, Contributing, Deployment Guide)
  • 80%+ test coverage across all packages
  • Multi-platform binary releases (Linux, macOS, Windows amd64/arm64)
  • Homebrew tap support for easy installation
  • Automated CI/CD pipeline with testing, linting, and releasing

Changed

  • Stabilized CLI interface for production use
  • Standardized configuration format (YAML) for backward compatibility
  • Achieved comprehensive test coverage across all modules

Security

  • Age (X25519) encryption for all API keys
  • Automatic key rotation with kairo rotate command
  • 0600 file permissions on sensitive files (config, secrets.age, age.key)
  • Secrets decrypted in-memory only
  • No plaintext API keys stored in configuration files

v0.5.3

Choose a tag to compare

@github-actions github-actions released this 27 Dec 17:23

Added

  • Version tests: Added internal/version/version_test.go with 5 tests for version parsing and validation
  • UI output tests: Added internal/ui/prompt_test.go with comprehensive tests for all Print functions
  • cmd package tests: Expanded test coverage from 29% to 36.3% with new tests for:
    • ensureConfigDirectory, loadOrInitializeConfig, loadSecrets
    • parseProviderSelection, configureAnthropic
    • checkForUpdates (update notification logic)
  • Semver dependency: Added github.com/Masterminds/semver/v3 for proper version comparison

Changed

  • Semver parsing: Replaced fragile string comparison with proper Masterminds/semver library
    • Fixes edge cases: v0.9.0 vs v0.10.0, pre-release versions, multi-digit version numbers
  • getEnvValue(): Implemented using os.Getenv() to enable KAIRO_UPDATE_URL environment variable override

Fixed

  • UI constants: Removed unused lowercase duplicate constants, all functions now use uppercase constants (Green, Yellow, Red, etc.)
  • Code cleanup: Updated CODE_REVIEW.md to reflect all completed items

v0.5.2

Choose a tag to compare

@github-actions github-actions released this 27 Dec 16:13

Fixed

  • kairo update: Fixed install script execution so it properly runs instead of just printing to terminal