SwiftDocAutomator
1.0.0
SwiftDoCautomatorは、公式のAppleおよびSwiftガイドラインに従って、Swiftコードのドキュメントコメントを自動的に生成する強力なツールです。コードを分析し、簡潔で理解しやすいドキュメントを作成することで、時間と労力を節約できます。
SwiftDoCautomatorをインストールするには、リポジトリをクローンして必要な依存関係をインストールするだけです。
git clone https://github.com/Saik0s/SwiftDocAutomator.git
cd SwiftDocAutomator
pip install -r requirements.txtswiftdocautomatorを使用するには、次のコマンドを実行します。
python main.py /path/to/your/swift/file.swiftこれにより、公式のAppleおよびSwiftガイドラインに従って、指定されたSwiftファイルのすべての機能とプロパティのドキュメントコメントが生成されます。
次の迅速な関数があるとします。
internal static func _typeMismatch ( at path : [ CodingKey ] , expectation : Any . Type , reality : Any ) -> DecodingError {
let description = " Expected to decode ( expectation ) but found ( _typeDescription ( of : reality ) ) instead. "
return . typeMismatch ( expectation , Context ( codingPath : path , debugDescription : description ) )
}swiftdocautomatorは、次のドキュメントコメントを生成します。
/// Returns a `.typeMismatch` error describing the expected type.
///
/// - parameter path: The path of `CodingKey`s taken to decode a value of this type.
/// - parameter expectation: The type expected to be encountered.
/// - parameter reality: The value that was encountered instead of the expected type.
/// - returns: A `DecodingError` with the appropriate path and debug description. あなたが持っているかもしれない貢献を喜んで受け取ります。提案、バグレポート、または機能のリクエストがある場合は、GitHubリポジトリで問題を公開してください。あなたのフィードバックは私にとって価値があり、あなたが提供できるどんな入力にも感謝しています。
SwiftDoCautomatorはMITライセンスの下でリリースされます。詳細については、ライセンスファイルを参照してください。