One day I saw this tweet from my friend Marco Sero
Shout-out to @phatblat who today saved me a lot of time adding Swift support to the Yammer app with his script https://t.co/oEwdRVaeDq
— Marco Sero (@marcosero) July 21, 2015
It looked liked something I should have take note of. So I obviously forgot about it.
Some days ago I set up the automated build distribution pipeline for a new client, with an app using a bit of Swift. I usually use something similar to this script. It is a pretty battle tested script, but something when wrong.
And that's when I remembered Marco's tweet and phatblat's script.
Download the raw script from here, place it somewhere, maybe in the project's root, then simply replace the xcodebuild -exportArchive
command with:
bin/package-swift-ipa.sh "$archive_path" "$(pwd)/$ipa_path"
Notice the $(pwd)
in the second argument. That's because the script is expecting absolute paths, while mine uses relative ones.
Leave the codebase better than you found it.