inject phonegap and battery scripts