xcodebuild's inability to just build against a specific SDK without also knowing which goddamn specific destination to use is such a waste of time I mean just choose one please its been like a decade please why just build it doesn't matter
@mattiem I’m sure you know about the generic destinations you can provide, right? (You can see how we invoke those on @SwiftPackageIndex if you click through to the details of Xcode builds in case you don’t!)

@finestructure hmmmm ok so I have tried this years ago, but cannot recall. I just gave it a shot and am encountering this:

"xcodebuild: error: Failed to build workspace XYZ with scheme XYZ.: Cannot test target “XYZTests” on “Any iOS Device”: Tests must be run on a concrete device"

Perhaps this works only for builds but not for running tests?

@mattiem Oh right, that’s got to be it. We only build, we don’t run tests, and it makes sense. Cross-compiling is one thing but when launching, you need a device.

@mattiem @finestructure I updated my ActionBuilderPlugin recently to pick a device at CI-runtime, as it was getting on my nerves. Especially annoying when baked into a CI script and then Xcode is updated and the old device no longer exists.

Not sure if I've actually pushed that code into a release yet, but it ends up generating this sort of thing:

https://github.com/elegantchaos/Logger/blob/e0514867a7b2f49f0a0ade1a4a23164b1afa73b8/.github/workflows/tests.yml#L203

Which is ugly, but works. Boiling all that down into something cleaner is on my to do list!

(https://github.com/elegantchaos/ActionBuilderPlugin)

Logger/.github/workflows/tests.yml at e0514867a7b2f49f0a0ade1a4a23164b1afa73b8 · elegantchaos/Logger

Configurable logging for Swift. Contribute to elegantchaos/Logger development by creating an account on GitHub.

GitHub

@samdeane @finestructure I have not tried it yet but I *think* that is basically what this is doing internally:

https://github.com/mxcl/xcodebuild

@mattiem @finestructure ah, cool!

I’ve been thinking that I should try to turn my plugin into an action as it makes a lot more sense in some ways.