jpsim / SourceKitten

An adorable little framework and command line tool for interacting with SourceKit.
MIT License
2.31k stars 226 forks source link

Add argument to specify output directory for `swift` or `xcodebuild` logs #787

Open art-divin opened 1 year ago

art-divin commented 1 year ago

Context

The default method of calculating build result output directory in Module.swift's init?(spmArguments:spmName:inPath) cannot be set from the outside:

let file = URL(fileURLWithPath: NSTemporaryDirectory()).appendingPathComponent("swift-build-\(UUID().uuidString).log")

When using CI like CircleCI, /tmp/ may not be available and due to nature of artefacts spec in config.yaml, it would be great to be able to control output directory for Module command's processes 'swift' and 'xcodebuild' as an argument.