Skip to content

Commit a9e5eb9

Browse files
kateinoigakukunbnbarham
authored andcommitted
Rename back to swift package completion-tool
The subcommand seems accidentally renamed to `swift package completion-command` while renaming the type name in #7336 This change renames it back to `swift package completion-tool` keep compatibility with the previous version.
1 parent bdcf60f commit a9e5eb9

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

Sources/Commands/PackageCommands/CompletionCommand.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ import var TSCBasic.stdoutStream
1818
extension SwiftPackageCommand {
1919
struct CompletionCommand: SwiftCommand {
2020
static let configuration = CommandConfiguration(
21+
commandName: "completion-tool",
2122
abstract: "Completion command (for shell completions)"
2223
)
2324

Tests/CommandsTests/PackageCommandTests.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,11 @@ final class PackageCommandTests: CommandsTestCase {
6767
XCTAssertMatch(stdout, .contains("Swift Package Manager"))
6868
}
6969

70+
func testCompletionTool() throws {
71+
let stdout = try execute(["completion-tool", "--help"]).stdout
72+
XCTAssertMatch(stdout, .contains("OVERVIEW: Completion command (for shell completions)"))
73+
}
74+
7075
func testInitOverview() throws {
7176
let stdout = try execute(["init", "--help"]).stdout
7277
XCTAssertMatch(stdout, .contains("OVERVIEW: Initialize a new package"))

0 commit comments

Comments
 (0)