Closed pkluz closed 7 years ago
I think the run script is run after the sources in cocoa pods are already built. So when it goes to compile, it won't reflect the changes done by the script. I can't figure out how to get the script to run just before the pods are built. Alternatively maybe the cocoapods post_install hook can work? I don't know if the script can be called from there properly though.
I'm tackling this now, I'm removing the prepare_command
from the Podspec, I don't think that's the right tool for the job.
Sorry, probably should've mentioned that I started looking into this. FYI, yeah I'm moving to a post_install
hook. There might be some rough edges though, we'll see...
I found another way to do this and it's stupidly simple. We can actually edit the scheme and add a pre-action to build to run our script...
Can this be automated such that all the end-user needs to do is to run pod install
?
The post install may be able to do this. There's the xcodeproj gem that lets us edit the proj file. I'm not efficient enough with ruby though. Maybe @allewun knows?
@chhaylatte ha.. let me digest this for a second. In the meantime, have a look at #17
Closed via #17
@allewun @chhaylatte When compiling a project that includes OriginateTheme for the first time, compilation tends to fail despite the
Run Script
phase being executed before theCompile Sources
phase. Is the list of sources to compile not being updated correctly and working off of stale data perhaps?