Stavros_S
Stavros_S

Reputation: 2235

Errors with nativescript-push-notification when building for Android

I'm receiving the following build errors when trying to test a simple app that can register and receive push notifications. I'm using the nativescript-push-notification plugin. below is the error which displays in the terminal, any advice? I updated the manifest file according based on the plugin docs.

Could not resolve all dependencies for configuration ':_nativescript-push-notificationsDebugCompile'. Could not find com.google.android.gms:play-services-gcm:8.4.0. Searched in the following locations: https://jcenter.bintray.com/com/google/android/gms/play-services-gcm/8.4.0/play-services-gcm-8.4.0.pom https://jcenter.bintray.com/com/google/android/gms/play-services-gcm/8.4.0/play-services-gcm-8.4.0.jar file:/Users/stevenstratis/Documents/Developer/ns-pushtest/platforms/android/libs/aar/play-services-gcm-8.4.0.jar file:/Users/stevenstratis/Documents/Developer/ns-pushtest/platforms/android/libs/aar/play-services-gcm.jar file:/usr/local/opt/android-sdk/extras/android/m2repository/com/google/android/gms/play-services-gcm/8.4.0/play-services-gcm-8.4.0.pom file:/usr/local/opt/android-sdk/extras/android/m2repository/com/google/android/gms/play-services-gcm/8.4.0/play-services-gcm-8.4.0.jar Required by: :nspushtest:unspecified

Upvotes: 1

Views: 223

Answers (1)

Nathanael
Nathanael

Reputation: 5399

I'm not 100% sure; but based on the error I would guess you need to type: android (Assuming your android sdk tools are in your path, otherwise you need to switch to the folder you installed the Android SDK to run it.)

Then choose in the list of things that your can install towards the bottom the Google Play Services. Also make sure you have Android Support Library and Android Support Repository downloaded also. You might need some of the additional Google Play Libraries listed, so if you have the disk space I would recommend you just install all the Google Play Libraries.

Once those are installed then when you go to build your app; they should be found; but if you don't have them you will get an error like the above.

Upvotes: 0

Related Questions