Skip to content

Commit c03a157

Browse files
author
Eric Miller
committed
Refactor command line argument name
1 parent 4e50090 commit c03a157

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

Sources/UBKit/UBKit.swift

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,10 @@ public final class UBKit {
6161
}
6262

6363
switch arg {
64+
case .config:
65+
createConfiguration(workingPath: workingPath, completion)
6466
case .initialize:
65-
initialize(workingPath: workingPath, completion)
67+
break
6668
case .generate:
6769
generate(manager: kitManager, completion)
6870
}
@@ -82,11 +84,12 @@ public final class UBKit {
8284
private extension UBKit {
8385

8486
enum Argument: String {
87+
case config
8588
case initialize = "init"
8689
case generate
8790
}
8891

89-
func initialize(workingPath: String, _ completion: @escaping ((Error?) -> Void)) {
92+
func createConfiguration(workingPath: String, _ completion: @escaping ((Error?) -> Void)) {
9093
guard fileManager.createFile(
9194
atPath: workingPath.appending("ubconfig.json"),
9295
contents: File.configFile(),

0 commit comments

Comments
 (0)