The Mac OS is notifying that the command "phonegap" cannot be found: -bash: phone

After successfully installing phonegap and cordova on my Macbook (Mac OS X Mountain Lion) using the following npm commands:

sudo npm install -g cordova
sudo npm install -g phonegap

It appeared that both Phonegap and Cordova were installed without any issues. However, when I attempted to run the commands:

myMac:~ user$ cordova
myMac:~ user$ phonegap

I received the error messages:

-bash: cordova: command not found
-bash: phonegap: command not found

Even though both programs were installed, it seems like the commands are not working properly. Why is this happening?

Answer №1

Although this question may be old, my answer could still provide valuable assistance.

I encountered the same issue and resolved it by creating a symbolic link:

cd /usr/local/bin/
sudo ln -s /usr/local/Cellar/node/6.0.0/bin/phonegap phonegap
sudo ln -s /usr/local/Cellar/node/6.0.0/bin/cordova cordova

Make sure to adjust the path /usr/local/Cellar/node/6.0.0/bin/ to match your specific installation directory.

[]s

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Ensuring compatibility of peerDependencies through devDependencies in npm3

With the recent update to NPM 3, automatic resolving of peer dependencies has been removed. This poses a challenge when developing a plugin/library for consumption by another application. If the underlying library uses peerDependencies, it requires manual ...

I'm having trouble locating the module "script!foundation-sites/dist/foundation.min.js on Heroic."

This is the content of my webpack.config.js file: var webpack = require('webpack'); var path = require('path'); process.env.NODE_ENV = process.env.NODE_ENV || 'development'; module.exports = { entry: [ 'script!jque ...

Streamlining Website Traffic Through Automation

I am seeking ways to increase the views on my website using only my Mac computer. I am open to all suggestions and options available. If necessary, I can provide more details to clarify my question further. Initially, I am aiming for a rise in basic hits ...

Angular 4 Query Building Plugin

Looking for a query builder plugin compatible with Angular 4 to create nested queries in my project. Some options I found include: https://www.npmjs.com/package/angular2-query-builder (Requires Angular 4+ ) (For AngularJS) (For Angular JS). The c ...

GitHub Action encounters a fatal error during the build process

As a new face in the DevOps world, I've decided to take the plunge and experiment with setting up a straightforward GitHub Action. My goal is to have my website automatically deployed to Firebase whenever I push changes to the master branch. However, ...

unsuccessful transformation using TopoJSON

After successfully installing topojson using the command sudo npm install -g topojson, I encountered issues converting both a shapefile (.shp) and a geojson file to a topojson file. Alexanders-MacBook-Pro:topojson alexander$ geo2topo Parcel11_projected.ge ...

What is the reasoning behind Meteor's decision to utilize its proprietary Package Manager Atmosphere instead of npm?

Even though Meteor is built on pure JavaScript, it diverges from the standard practice of using CommonJS modules or NPM packages by introducing its own unique package manager called Atmosphere. What led to this decision? ...

The module was not found: Unable to locate the file './AppAPI' in the project directory

Despite setting up my react app correctly, I keep encountering an error. I have all my code in a file called App.API.js within the src folder. The issue seems to be originating from the index.js file, where the code is: import App from './AppAPI&apo ...

Encountering a hindrance with NPM proxy while attempting to globally install Vue CLI

I have encountered an issue while trying to install Vue Cli globally. The installation process is not completing and I am receiving errors related to proxy settings. I tried to manually add values to the .npmrc file as shown below, but it did not resolve t ...

Encountered an issue while trying to install tailwindcss-elevation

Currently, I am facing dependency issues while attempting to install multiple npm packages in my main test_project directory. Here is a breakdown of the steps I took before encountering errors: npm init -y npm install -D tailwindcss@latest postcss@lates ...

Error: Angular7 Unable to locate namespace 'google'

I am currently utilizing the import { MapsAPILoader } from '@agm/core'; package to enable auto-complete address search functionality. However, I have encountered an error message stating cannot find namespace 'google'. The error occu ...

Error: An issue occurred with the tasks in the Gruntfile.js file

pm WARN EPACKAGEJSON <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="74041506001a1106041b0600151834445a445a44">[email protected]</a> No description npm WARN EPACKAGEJSON <a href="/cdn-cgi/l/email-protection" ...

Global installation of Node app causes discrepancies in processing of escape characters within paths

I'm completely new to Node.js, so I'm sure there's a straightforward answer to this question... I'm working on an app that requires a file path input. This path is generated by dragging a file into the Terminal window, resulting in a p ...

Exploring the possibilities of Slick-Carousel integration with the help of N

Struggling to conquer NPM and encountering obstacles. My slick-carousel functions perfectly with the CDN method. However, since I am using NPM for everything else, I decided to do the same for this plugin, but I can't seem to make it work. Executed ...

What is the reason behind the abundance of packages in my node_modules directory?

As a newcomer to app development, I followed the npm create-react-app documentation to create my first app. However, I noticed that there were numerous packages included in the node_module folder that weren't essential for my basic use of React and Re ...

Can you explain the functionality of 'npm install -g '?

I tried to create a private npm registry using sinopia and I ran into an issue after executing npm install -g sinopia. Here is the error message that appeared: > <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="9ffcede6efebac ...

I'm having trouble installing axios using npm

I am in the process of developing an express app that will utilize IGDB's api, and I initially planned to use axios. However, upon attempting to install axios with npm, I encountered the following error: npm ERR! code EACCES npm ERR! syscall rename np ...

Encountering a white screen and MIME Type Error when attempting to deploy a Vite app on GitLab Pages

I am facing an issue while trying to deploy my Vite application on Gitlab Pages. The page only displays a blank screen and the following errors are shown: The CSS and JS files from the static directory cannot be loaded due to MIME type mismatch (X-Content ...

Struggling to deploy a Reactjs application on Azure, encountering deployment failure

My attempt to launch my reactjs application on Azure cloud platform has hit a roadblock. I have designated the git repository as the deployment source, but my deployment is failing due to numerous npm errors. The azure error log shows the following: C ...

Issue with Npm mysql and AWS Lambda: Query cannot be enqueued after invoking quit command

Currently, I am in the process of creating various AWS Lambda functions for testing purposes. To connect to the RDS database, I'm utilizing the npm mysql package. The code provided below functions properly. However, after every alternate function exec ...