From 6b2aa2748a7881eebb9f84fb10c01293e15b52ca Mon Sep 17 00:00:00 2001 From: Nate Cook Date: Fri, 3 Sep 2021 12:30:52 -0500 Subject: [PATCH] Update CHANGELOG for release 0.5.0 (#351) --- CHANGELOG.md | 78 ++++++++++++++++++++++++++++- Documentation/01 Getting Started.md | 2 +- README.md | 4 +- 3 files changed, 79 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bfc3017aa..745dff17e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,7 +8,7 @@ This project follows semantic versioning. While still in major version `0`, source-stability is only guaranteed within minor versions (e.g. between `0.0.3` and `0.0.4`). If you want to guard against potentially source-breaking package updates, you can specify your package dependency using -`.upToNextMinor(from: "0.4.0")` as the requirement. +`.upToNextMinor(from: "0.5.0")` as the requirement. ## [Unreleased] @@ -16,6 +16,60 @@ package updates, you can specify your package dependency using --- +## [0.5.0] - 2021-09-02 + +### Additions + +- When a user doesn't provide a required argument, the error message now + includes that argument's help text. ([#324]) +- Command-line tools built with `ArgumentParser` now include an experimental + flag to dump command/argument/help information as JSON: + `--experimental-dump-help`. ([#310]) + +### Changes + +- All public enumerations are now structs with static properties, to make + compatibility with future additions simpler. + +### Fixes + +- Array properties defined as `@Option` with the `.upToNextOption` parsing + strategy now include all provided values. ([#304]) In the example below, all + four values are now included in the resulting array, where only the last two + were included in previous releases: + + ```swift + struct Example: ParsableCommand { + @Option(parsing: .upToNextOption) + var option: [String] + } + ``` + ``` + $ example --option one two --option three four + ``` + +- When a command defines an array property as an `@Argument` with the + `.unconditionalRemaining` parsing strategy, option and flag parsing now stops + at the first positional argument or unrecognized flag. ([#333]) +- Completion scripts correctly use customized help flags. ([#308]) +- Fixes errors with bash custom completion arguments and the executable path. + ([#320], [#323]) +- Fixes the behavior when a user specifies both the `help` subcommand and a help + flag. ([#309]) +- A variety of internal improvements. ([#315], [#316], [#321], [#341]) + +The 0.5.0 release includes contributions from [atierian], [compnerd], +[dirtyhabits97], [Frizlab], [KS1019], [natecook1000], and [rauhul]. Thank you! + +--- + +## [0.4.4] - 2021-07-30 + +### Fixes + +- Includes a workaround for a runtime crash with certain `OptionGroup` + configurations when a command is compiled in release mode. + ## [0.4.3] - 2021-04-28 ### Additions @@ -461,7 +515,9 @@ This changelog's format is based on [Keep a Changelog](https://keepachangelog.co -[Unreleased]: https://github.com/apple/swift-argument-parser/compare/0.4.3...HEAD +[Unreleased]: https://github.com/apple/swift-argument-parser/compare/0.5.0...HEAD +[0.5.0]: https://github.com/apple/swift-argument-parser/compare/0.4.4...0.5.0 +[0.4.4]: https://github.com/apple/swift-argument-parser/compare/0.4.3...0.4.4 [0.4.3]: https://github.com/apple/swift-argument-parser/compare/0.4.2...0.4.3 [0.4.2]: https://github.com/apple/swift-argument-parser/compare/0.4.1...0.4.2 [0.4.1]: https://github.com/apple/swift-argument-parser/compare/0.4.0...0.4.1 @@ -488,6 +544,19 @@ This changelog's format is based on [Keep a Changelog](https://keepachangelog.co [#256]: https://github.com/apple/swift-argument-parser/pull/256 [#276]: https://github.com/apple/swift-argument-parser/pull/276 [#290]: https://github.com/apple/swift-argument-parser/pull/290 +[#299]: https://github.com/apple/swift-argument-parser/pull/299 +[#304]: https://github.com/apple/swift-argument-parser/pull/304 +[#308]: https://github.com/apple/swift-argument-parser/pull/308 +[#309]: https://github.com/apple/swift-argument-parser/pull/309 +[#310]: https://github.com/apple/swift-argument-parser/pull/310 +[#315]: https://github.com/apple/swift-argument-parser/pull/315 +[#316]: https://github.com/apple/swift-argument-parser/pull/316 +[#320]: https://github.com/apple/swift-argument-parser/pull/320 +[#321]: https://github.com/apple/swift-argument-parser/pull/321 +[#323]: https://github.com/apple/swift-argument-parser/pull/323 +[#324]: https://github.com/apple/swift-argument-parser/pull/324 +[#333]: https://github.com/apple/swift-argument-parser/pull/333 +[#341]: https://github.com/apple/swift-argument-parser/pull/341 @@ -496,6 +565,7 @@ This changelog's format is based on [Keep a Changelog](https://keepachangelog.co [aleksey-mashanov]: https://github.com/apple/swift-argument-parser/commits?author=aleksey-mashanov [AliSoftware]: https://github.com/apple/swift-argument-parser/commits?author=AliSoftware [artemnovichkov]: https://github.com/apple/swift-argument-parser/commits?author=artemnovichkov +[atierian]: https://github.com/apple/swift-argument-parser/commits?author=atierian [BradLarson]: https://github.com/apple/swift-argument-parser/commits?author=BradLarson [buttaface]: https://github.com/apple/swift-argument-parser/commits?author=buttaface [CodaFi]: https://github.com/apple/swift-argument-parser/commits?author=CodaFi @@ -503,9 +573,11 @@ This changelog's format is based on [Keep a Changelog](https://keepachangelog.co [CypherPoet]: https://github.com/apple/swift-argument-parser/commits?author=CypherPoet [damuellen]: https://github.com/apple/swift-argument-parser/commits?author=damuellen [dduan]: https://github.com/apple/swift-argument-parser/commits?author=dduan +[dirtyhabits97]: https://github.com/apple/swift-argument-parser/commits?author=dirtyhabits97 [drewmccormack]: https://github.com/apple/swift-argument-parser/commits?author=drewmccormack [elliottwilliams]: https://github.com/apple/swift-argument-parser/commits?author=elliottwilliams [erica]: https://github.com/apple/swift-argument-parser/commits?author=erica +[Frizlab]: https://github.com/apple/swift-argument-parser/commits?author=Frizlab [glessard]: https://github.com/apple/swift-argument-parser/commits?author=glessard [gmittert]: https://github.com/apple/swift-argument-parser/commits?author=gmittert [griffin-stewie]: https://github.com/apple/swift-argument-parser/commits?author=griffin-stewie @@ -517,6 +589,7 @@ This changelog's format is based on [Keep a Changelog](https://keepachangelog.co [jonathanpenn]: https://github.com/apple/swift-argument-parser/commits?author=jonathanpenn [kennyyork]: https://github.com/apple/swift-argument-parser/commits?author=kennyyork [klaaspieter]: https://github.com/apple/swift-argument-parser/commits?author=klaaspieter +[KS1019]: https://github.com/apple/swift-argument-parser/commits?author=KS1019 [kylemacomber]: https://github.com/apple/swift-argument-parser/commits?author=kylemacomber [Lantua]: https://github.com/apple/swift-argument-parser/commits?author=Lantua [lorentey]: https://github.com/apple/swift-argument-parser/commits?author=lorentey @@ -528,6 +601,7 @@ This changelog's format is based on [Keep a Changelog](https://keepachangelog.co [NicFontana]: https://github.com/apple/swift-argument-parser/commits?author=NicFontana [owenv]: https://github.com/apple/swift-argument-parser/commits?author=owenv [pegasuze]: https://github.com/apple/swift-argument-parser/commits?author=pegasuze +[rauhul]: https://github.com/apple/swift-argument-parser/commits?author=rauhul [rjstelling]: https://github.com/apple/swift-argument-parser/commits?author=rjstelling [Sajjon]: https://github.com/apple/swift-argument-parser/commits?author=Sajjon [schlagelk]: https://github.com/apple/swift-argument-parser/commits?author=schlagelk diff --git a/Documentation/01 Getting Started.md b/Documentation/01 Getting Started.md index 9fcad963b..0a2e14e90 100644 --- a/Documentation/01 Getting Started.md +++ b/Documentation/01 Getting Started.md @@ -19,7 +19,7 @@ import PackageDescription let package = Package( name: "random", dependencies: [ - .package(url: "https://github.com/apple/swift-argument-parser.git", from: "0.4.0"), + .package(url: "https://github.com/apple/swift-argument-parser.git", from: "0.5.0"), ], targets: [ .target( diff --git a/README.md b/README.md index 18f8343ff..513478a1f 100644 --- a/README.md +++ b/README.md @@ -88,7 +88,7 @@ To use the `ArgumentParser` library in a SwiftPM project, add the following line to the dependencies in your `Package.swift` file: ```swift -.package(url: "https://github.com/apple/swift-argument-parser", from: "0.4.0"), +.package(url: "https://github.com/apple/swift-argument-parser", from: "0.5.0"), ``` Because `ArgumentParser` is under active development, @@ -97,7 +97,7 @@ If you don't want potentially source-breaking package updates, use this dependency specification instead: ```swift -.package(url: "https://github.com/apple/swift-argument-parser", .upToNextMinor(from: "0.4.0")), +.package(url: "https://github.com/apple/swift-argument-parser", .upToNextMinor(from: "0.5.0")), ``` Finally, include `"ArgumentParser"` as a dependency for your executable target: