Swiftpack.co - Package - BinaryBirds/SPM

SPM (📦)

SPM is a Swift wrapper around the Swift Package Manager.

Usage

Some basic examples:

import SPM

let spm = SPM(path: "~/spm-test")
try spm.run(.package(.initialize(.executable)))

try spm.run(.build, flags: [
    .config(.debug), 
    .stdlib(true)
])
try spm.run(.run, flags: [
    .config(.release)
])

try spm.run(.package(.clean))
try spm.run(.test)
try spm.run(.build, flags: [
    .config(.release), 
    .showBinaryPath
])
try spm.run(.package(.describe), flags: [
    .raw("--type json")
])
try spm.run(.run, flags: [
    .macro("DEBUG"),
    .target("x86_64-apple-macosx10.12")
])

// async execution
spm.run(.build, flags: [.config(.release)]) { result, error in
    //...
}

Install

Just use the Swift Package Manager as usual:

.package(url: "https://github.com/binarybirds/spm", from: "1.0.0"),

⚠️ Don't forget to add "SPM" to your target as a dependency!

License

WTFPL - Do what the fuck you want to.

Github

link
Stars: 0
Help us keep the lights on

Dependencies

Used By

Total: 1

Releases

1.0.0 - Jan 2, 2019

SPM is a Swift wrapper around the official Swift Package Manager.