Push plugin issue on iOS ionic

Hello all,

I have trying to installing ionic push plugin in my project. But, I have got the following error.

Installing “phonegap-plugin-push” for ios
Failed to install ‘phonegap-plugin-push’: undefined
Error:
/Library/Ruby/Gems/2.0.0/gems/claide-1.0.2/lib/claide/command.rb:439:in
`help!’: [!] You cannot run CocoaPods as root. (CLAide::Help)

I have to install the cocopod as well as run ‘pod setup’ this command. But, unfortunately, no luck.

Please can anyone help me this out

Thanks in advanced!

which plugins are you used to made?

I have refer this http://ionicframework.com/docs/native/push/

first you have get the device id and then you will be elaborate the codes.Specially used for api concept

I have a similar problem with Cocopods with the new Ionic Pro

Here is the error I’m getting for my IOS. The package that breaks is Intercom.

Ah man!. It doesn’t look like you have CocoaPods installed.

You have two choices.

  1. Install Cocoapods:
    $ sudo gem install cocoapods
  2. Manually install the dependencies.
    –save flag or autosave detected
    Saving ios@~4.3.1 into config.xml file …
    Update IOS build setting SWIFT_OBJC_BRIDGING_HEADER to: “$(PROJECT_DIR)/$(PROJECT_NAME)/Bridging-Header.h” for build configuration Debug
    Update IOS build setting SWIFT_OBJC_BRIDGING_HEADER to: “$(PROJECT_DIR)/$(PROJECT_NAME)/Bridging-Header.h” for build configuration Release
    Update IOS build setting ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES to: YES for build configuration Debug
    Update SWIFT version to 3.0 Debug
    Update IOS build setting SWIFT_OPTIMIZATION_LEVEL to: -Onone for build configuration Debug
    Update IOS build setting ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES to: YES for build configuration Release
    Update SWIFT version to 3.0 Release
    e[32;1mRunning after script…e[0;m
    e[32;1m$ clean-upe[0;m
    Cleaning up files…
    Successful clean up
    e[31;1mERROR: Job failed: exit status 1
    e[0;m

I personally use OneSignal,
but try …

Granting permissions to root?
It says [!] You cannot run CocoaPods as root.

Try this:
sudo ionic cordova plugin add phonegap-plugin-push --save

That might help?
You may be asked to enter your password cause you’re running it as sudo.

If it keeps happening; mind sharing if you have the following?

  • npm (node.js)
  • cordova
  • ionic
  • CocoaPods