How to automatically delete old built archives in xcode continuous integration?
build, continuous-integration, xcode
Solution
The only useable solutions I found so far is using the REST api of the Xcode server.
Basically you write a script to get all the IDs of the old integrations (using the filter API) and then delete them. Trigger the script from a cron job or jenkins.
https://developer.apple.com/library/ios/documentation/Xcode/Conceptual/XcodeServerAPIReference/Integrations.html#//apple_ref/doc/uid/TP40016472-CH3-SW2
Alternative:
Delete all the old integrations from your Xcode server in the file system under /Library/Developer/XcodeServer/IntegrationAssets/
https://honzadvorsky.com/articles/2015-05-04-under-the-hood-of-xcode-server/
If anyone come up with a easier solutions: I'm all ears.
Problem
I'm using a bot to integrate/build my project with xcode continuous integration. With Jenkins, I can define the max number of builds I want to keep. Is there a possibility to achieve this with xcode ci with an automated process? Thank you