Releases: joseluisq/cline
Releases · joseluisq/cline
v1.0.0
This release introduces the first major version v1.0.0.
Breaking changes
Although changes are expected to be minor, existing code needs to be updated.
- Golang 1.23 is required as a minimum.
- API is changed.
Apptype is decoupled from theHandlerlogic, resulting in a newHandlertype.- Some structs are renamed like
Flagtypes,Flagvalues,Cmdsand helpers.
Refactorings
- Restructured project modules (files and directories).
- Improved Tests and code coverage CI, as well as refactored a few APIs.
Improvements
- Strict UTF-8 for arguments and alphanumeric ASCII for flags and commands.
- POSIX-compliant support is partially supported (see the limitations).
- Support for flags termination via
--to provide further positional arguments (tail args). - If flag arguments are duplicated (the same argument is used multiple times), then the last argument and value will be taken.
- Option to restrict the maximum argument length and the maximum number of arguments provided.
Fixes
- Inconsistent use of aliases for special
versionandhelpflags like--vor--h.
For using the new API, please review the examples to adjust your existing apps accordingly.
the ./examples directory.
For more details, see the v1.0.0 milestone and the full changelog v0.1.0...v1.0.0.
v0.1.0
Refactorings
- af2f02e Help flag display improvements. Which redefine spaces and output style.
Breaking changes
- 8c2065b Improve flag values, types and helpers. Every flag value type now returns an error during conversion instead of just panic.
Features
- b21365e Build commit support in --version flag.
Codebase
- 1a366ec Github Actions as new CI.
Testing
- ddb3bc5 Test cases for flag values.
v0.1.0-beta.9
Refactorings
- c31151d Flag types and values API improved.
Fixes
- 8c0761e Wrong bool flag values passed to subommands.
Features
- 51d02e9 Get provided flags function.
- 22b81cb Get provided flags with long names function.
- 2d3c8a1 Get provided flags with short names (alias) function.
Documentation
- 9fb6a24 Update code example with new API.
v0.1.0-beta.8
Refactorings
- 710aa27 Version flag for global only.
v0.1.0-beta.7
v0.1.0-beta.6
Features
- 966d25e
FlagProvidedstruct for flags passed only from stdin. Available onAppContext.FlagsandCmdContext.Flags.
Refactorings
v0.1.0-beta.5
Refactorings
- 19a506b Dereference tail args slice on app and command contexts.
v0.1.0-beta.4
Refactorings
- 76a9e44 Handle short and long
boolflag values.
v0.1.0-beta.3
chore: minor testing tweaks
v0.1.0-beta.2
refactor: update code examples