File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed
Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -33,7 +33,13 @@ struct ApiKeyRepository {
3333 }
3434
3535 private func readNewKey( ) throws -> String {
36- printer. forcedOutput ( message: " Please enter your TinyPNG API key. More details at https://tinypng.com/developers " )
36+ let instructions = """
37+ Please enter your TinyPNG API key.
38+ If you already have a TinyPNG account, you can get the API key from: https://tinypng.com/dashboard/api.
39+ Otherwise, you can find more details at https://tinypng.com/developers.
40+ """
41+ printer. forcedOutput ( message: instructions)
42+
3743 let newKey = readLine ( ) ? . trimmingCharacters ( in: . whitespacesAndNewlines) ?? " "
3844 if !newKey. isEmpty {
3945 try write ( apiKey: newKey)
Original file line number Diff line number Diff line change @@ -4,7 +4,6 @@ import Files
44import Foundation
55
66struct FileMover {
7- let printer : CommandLinePrinter
87 let outputPath : String ?
98
109 func move( inputPath: String , from localUrl: URL ) throws {
Original file line number Diff line number Diff line change @@ -52,7 +52,7 @@ struct ImageCramCommand: ParsableCommand {
5252 }
5353
5454 let compressor = ImageCompressor ( apiKey: apiKey, printer: printer)
55- let mover = FileMover ( printer : printer , outputPath: output)
55+ let mover = FileMover ( outputPath: output)
5656
5757 for input in inputs {
5858 let result = try compressor. compress ( filePath: input)
You can’t perform that action at this time.
0 commit comments