Cannot load empty config.xml file (Android build)


#1

Hello,

I am trying to run an application on my Android phone. The result of it is getting this error for following the command.

ionic cordova run

2018-01-26 00_35_58-Program Manager

My Application’s ionic info.

Does someone has an answer for this problem ?

Thanks already :slight_smile:.


#2

Is your config.xml empty?
You app-scripts is super old, update to a current version.
Run npm uninstall ionic to get rid of that local install.
Also look for other local cli packages in package.json and run npm install after cleaning up.


#3

Yes config.xml is empty. I fixed this error now, Visual Studio caused the bug it deleted it overwrote something so the config.xml was empty then.

The Warning still appears of old versions. Should I maybe remove the whole node_modules folder and do a clean npm install then again ?

I tried running the command again it prints out this error. I gues its because I still have the older version or am I wrong ?

node error


[WARN] Detected locally installed Ionic CLI, but it's to old--using global CLI
#4

Your app-scripts is super old.
Your ionic info should list the platforms you have installed.

Try removing and re-adding the platforms.

Best try it with a new project with ionic start and see if you can get it running. If you can, make sure your project matches as close as possible.


#5

Hi, I am also getting the same error of config.xml getting cleared whnever running ionic run -l -c.
May I know the exact reason for this and how you solved it. It will be very useful.

Thanks.


#6

The problem was with my Visual Studio Branch. The config.xml file got overwritten if I remember right. But im still getting alot of errors after that small “fix”.

Im sorry I don’t have a solution for it :confused:


#7

Hey, thanks for the reply. Anyways will figure it out.


Config.xml turns empty
#8

ionic integrations enable cordova --add

I had same issue, config.xml got empty suddenly. Anyway, try the code i provided above and you will be asked to overwrite resources folder.

DONT ACCEPT OVERWRITE

choose no, then run your android. Overwriting your resources folder will lead to other issues.


#9

Thanks it Worked for me.


#10

thank you, it worked for me.


#11

I also got into the same problem.
Just delete the config.xml file and run this command to create a new one

ionic integrations enable cordova --add

This worked for me.