Unexpected argument when using `swift package plugin generate-manual <tool>`
メンテナーはふだん 3 日以内に返信
まだ誰も着手していません。
評価
調査の方向性
generate-manual Swift package plugin のエントリポイントから始め、報告されている Swift と ArgumentParser のバージョンを使ってコマンド swift package plugin generate-manual tuist --configuration debug を再現します。宣言されている <tool> 引数とプラグインに渡される引数を比較し、予期しない引数エラーなしでコマンドが完了することを確認して修正を検証します。
索引モデルが issue の本文から書いたものです。
説明
I'm trying to use the generate-manual plugin in this repository by using the following command: swift package plugin generate-manual tuist --configuration debug. However, the command fails with an error Error: Unexpected argument 'tuist'. It seems that the argument parsing logic is unable to recognize the tool argument, even though it's defined in it and shows up in the help menu.
ArgumentParser version: 1.4.0
Swift version:
swift-driver version: 1.90.11.1 Apple Swift version 5.10 (swiftlang-5.10.0.13 clang-1500.3.9.4)
Target: arm64-apple-macosx14.0
Checklist
- If possible, I've reproduced the issue using the
mainbranch of this package (commit:bb10ca8b70fe54c67a1b3adb0f5d58341dc2ed7b) - I've searched for existing GitHub issues
Steps to Reproduce
Clone the this repository and run the command swift package plugin generate-manual tuist --configuration debug.
Expected behavior
I'd expect the command to complete successfully.
Actual behavior
You get the following error:
Built package in debug mode
Generating manual for tuist...
Error: Unexpected argument 'tuist'
Usage: generate-manual <tool> [--multi-page] [--date <date>] [--section <section>] [--authors <authors> ...] --output-directory <output-directory>
See 'generate-manual --help' for more information.
error: 'generate-manual' invocation failed: ''generate-manual' invocation failed with a nonzero exit code: '64'.'
- 主要言語
- Swift
- スター
- 3.8k
- フォーク
- 436
- 平均マージ
- 4日 11時間
- マージ済み PR(30日)
- 2
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
apple/swift-argument-parser のほかの issue
-
documentation
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
apple/swift-argument-parser#1007 ·
メンテナーはふだん 3 日以内に返信
-
Tool tests fail under the Swift Build build system because `generate-manual` & `generate-docc-reference` are not built対応中かも @rgoldberg が 23 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
apple/swift-argument-parser#995 · コメント 1 件 ·
メンテナーはふだん 3 日以内に返信
-
Consider making `String.wrapped()` and `Platform.terminalWidth` public対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
apple/swift-argument-parser#973 · コメント 1 件 ·
メンテナーはふだん 3 日以内に返信
-
Include hidden args in completion scripts対応中かも @Galileo927 が 182 日前に担当しました。 オープンgood first issue
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
apple/swift-argument-parser#733 · コメント 7 件 ·
メンテナーはふだん 3 日以内に返信
-
Shared `@OptionGroup` flag is rejected after a subcommand when the root has a passthrough `defaultSubcommand`対応中かも @sean0407 が 22 日前に担当しました。 オープン
難易度 4/5 1〜2日 初心者へのやさしさ 48/100
apple/swift-argument-parser#994 ·
メンテナーはふだん 3 日以内に返信
apple/swift-argument-parser の issue をすべて見る