Skip to content

Commit 1eebdd9

Browse files
feat: print update msg to stderr
1 parent 1d4116d commit 1eebdd9

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

Sources/Swiftly/Swiftly.swift

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,9 +100,16 @@ extension SwiftlyCommand {
100100

101101
return {
102102
if shouldUpdateSwiftly {
103-
ctx.print("----------------------------")
104-
ctx.print("A new release of swiftly is available")
105-
ctx.print("Please run `swiftly self-update` to update.")
103+
let errorMessage = """
104+
-----------------------------
105+
A new release of swiftly is available
106+
Please run `swiftly self-update` to update.
107+
-----------------------------\n
108+
"""
109+
110+
if let data = errorMessage.data(using: .utf8) {
111+
FileHandle.standardError.write(data)
112+
}
106113
}
107114
}
108115
}

0 commit comments

Comments
 (0)