mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 12:07:55 +00:00
Run SwiftFormat.
This commit is contained in:
@@ -4,21 +4,21 @@ import Foundation
|
||||
|
||||
struct OutdatedPackages: ParsableCommand {
|
||||
static let configuration = CommandConfiguration(abstract: "A tool to check outdated package dependencies. Please make sure you have already run setup-project before using this tool.")
|
||||
|
||||
|
||||
private var projectSwiftPMDirectoryURL: URL {
|
||||
.projectDirectory.appendingPathComponent("ElementX.xcodeproj/project.xcworkspace/xcshareddata/swiftpm")
|
||||
}
|
||||
|
||||
|
||||
func run() throws {
|
||||
try checkToolsDependencies()
|
||||
try checkProjectDependencies()
|
||||
}
|
||||
|
||||
|
||||
func checkToolsDependencies() throws {
|
||||
guard let output = try Zsh.run(command: "swift outdated"), !output.isEmpty else { return }
|
||||
print("outdated tools Swift packages:\n\(output)")
|
||||
}
|
||||
|
||||
|
||||
func checkProjectDependencies() throws {
|
||||
guard let output = try Zsh.run(command: "swift outdated", directory: projectSwiftPMDirectoryURL), !output.isEmpty else { return }
|
||||
print("outdated project Swift packages:\n\(output)")
|
||||
|
||||
Reference in New Issue
Block a user