My Cordova has suddenly stopped working.
It was working well when I was last working on it - around 2 months ago.
Now when I want to resume working on my project, it gives me the error:
> cordova platforms add android
npm http GET https://registry.npmjs.org/cordova-android/3.7.1
npm http 200 https://registry.npmjs.org/cordova-android/3.7.1
npm http GET https://registry.npmjs.org/cordova-android/-/cordova-android-3.7.1.tgz
npm http 200 https://registry.npmjs.org/cordova-android/-/cordova-android-3.7.1.tgz
Platform android already added.
> cordova run android
Running command: C:\Work\Eclipse\Workspace\Android\CordovaTmp\HelloWorld\platforms\android\cordova\run.bat
"C:\Work\Eclipse\Workspace\Android\CordovaTmp\HelloWorld\platforms\android\cordova\run"
ERROR: Error: Please install Android target "android-19".
Hint: Run "android" from your command-line to open the SDK manager.
ERROR running one or more of the platforms: Error: C:\Work\Eclipse\Workspace\Android\CordovaTmp\HelloWorld\platforms\android\cordova\run.bat: Command failed with exit code 2
You may not have the required environment or OS to run this project
> cordova -version
4.3.0
I have checked out these posts, but thats of no help: link 1, link 2 and link 3.
Also, I am unable to run 'android' on the cygwin shell even though I have added tools and platform-tools to my PATH variable in 'My Computer'
I am running Windows 8.1, cygwin and here is what my SDK Manager looks like:
My platforms/android/AndroidManifest.xml looks like:
<manifest android:hardwareAccelerated="true" android:versionCode="1" android:versionName="0.0.1" package="com.foo.helloworld" xmlns:android="http://schemas.android.com/apk/res/android">
<supports-screens android:anyDensity="true" android:largeScreens="true" android:normalScreens="true" android:resizeable="true" android:smallScreens="true" android:xlargeScreens="true" />
<uses-permission android:name="android.permission.INTERNET" />
<application android:hardwareAccelerated="true" android:icon="@drawable/icon" android:label="@string/app_name">
<activity android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale" android:label="@string/activity_name" android:launchMode="singleTop" android:name="CordovaApp" android:theme="@android:style/Theme.Black.NoTitleBar" android:windowSoftInputMode="adjustResize">
<intent-filter android:label="@string/launcher_name">
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
<uses-sdk android:minSdkVersion="10" android:targetSdkVersion="21" />
</manifest>