3
votes

I have installed Cordova on my Mac and developed an app. It is structured as follows:

  • config.xml
  • www
    • index.html
    • index.js
  • cordova
  • plugins
  • platforms

Note how config.xml is placed outside of the www folder.

Now, for using Phonegap Build, the config.xml must be placed next to the index.html. This makes it really inconvenient to switch between the two tools.

Is there any way I can teach Phonegap Build to look for the index.html file inside www folder, not next to config.xml?

1
Added my own solution below.Sergey Snegirev

1 Answers

2
votes

When building a project, Cordova first looks for config.xml in the project root folder, then in the /www/ folder, then in the /platform/android/assets/www or /platform/ios/[project_name].

So I just moved the config.xml from root into /www/ and was able to successfully build projects, thereby unified the config file locations for local Cordova and Phonegap Build. Voilà!