mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:33:26 +00:00
Automatically open a PR to bump the calver (#4167)
* Update our tools package to Swift 6.1
Also improves the package layout with subdirectories 📁
* Update GenerateSDKMocks to be an Async command.
* Add a tool to bump the project CalVer every month.
* Add a workflow to automatically bump the calendar version.
Note: This only does year & month, the patch is handled by the release script.
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
import ArgumentParser
|
||||
import CommandLineTools
|
||||
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