phonegap build + phonegap-cli + ionic icons

I am pretty sure what I am trying to accomplish is kind of extreme.. no wait, it isn't!

I just need to get the ionic resources+phonegap-cli+phonegap build combo right.

Now, here's the problem.

No matter how hard I try (because I probably am trying hard and wrong ^^ ) I can't get an ios build to show the icon files I am submitting to phonegap build. But I am beginning to consider the fault not entirely on pg:build side.

I have a root folder, with an /app application and a /resources folder. The latter is generated by ionic resources.

Now when I build for phonegap remote I have this structure in a /pgbuild folder I create ad hoc: /resources /www

The config.xml (which is in the main project root folder) contains the following entries:

Here's my ipa package contents:

Which is more or less what specificated in the phonegap build docs. In the docs there is no way I found to understand to which path these src are relative. To the root of the zip? to the root of the www? I've tried also to move /resources to /www, to no avail.

I've tried pretty every combination of folders and src, but I am missing something because the info.plist contains only:

CFBundleIconFiles = ( "icon.png", "icon-60.png", "icon-60@2x.png", "icon-76.png", "icon-76@2x.png", "icon-60@3x.png" );

which is weird because these icons are correct :) except for icon.png which doesn't get copied.

In one app I had this exact problem which prevented me to submit to the app store, I finally solved it but -believe me or not- I am not able to recreate this condition on another app.

These are the commands I run from my ionic app root:

ionic resources

to generate resources, then:

mkdir -p pgbuild/www; 
mkdir -p pgbuild/resources
cp -R ./resources/* ./pgbuild/resources 
cp -r ./www/* ./pgbuild/www; 
cp config.xml pgbuild/; 
cd pgbuild && phonegap remote build ios && cd .. ; 

Is phonegap-cli supported for this kind of remote build? Am I missing something?

@suprandr, I've got online Demo Apps on getting icons and splash screens working. The documentation for iOS is especially convoluted. (Should we blame middle managers for taking old documentation offline?) The notes on github include: On filesnames and how they are found for iOS

NOTE: I only use PhoneGapBuild. I've created boilerplates to get around this annoyance for remembering what I did the last time. Best of Luck, Jesse.

Here's what I found.

I understand that resources must be inside www, and the path in config.xml is relative to the www folder. That seems to fix the problem, even if you should increase the size of your app bundle this way (it would be better if phonegap could take resources outside of the www folder which is used by the application).

so if I have a

www/resources/ios/icon/something.png

in the config I should use

resources/ios/icon/something.png

Also, the ionic resources command embeds resources into <platform name="ios">

That doesn't seem to be appreciated by Phonegap Build.