Getting Started, Understanding Install Locations and Uninstall Process


#1

First post here, apologies if this is not the correct location for this type of question. I’m new to coding on a Mac and new to command line. I’m ready to start playing around with Ionic but since I have a new MacBook I’m curious about where all this stuff (node, npm, cordova/ionic command line tools, etc…) will be installed to on my machine. And if I decide to ever remove all of it how would I go about that? Thanks!


#2

If you’re getting involved in development the install locations and uninstalling things will be the least of your concerns. :wink:
I normally recommend the following tool as it makes a number of things easier when spending time on the command line:

Take it a step at a time and fear not experimenting, it’s a learning process.


#3

Right on, thanks. I’m not that worried about the coding, been coding for years. More concerned about learning this specific coding process / environment and git. In the past I’ve just used SublimeText and my own companies check in/out processes. But to my original question, I just like to keep my PC as clean as possible so I’d like to know how to remove all this stuff if for some reason down the road I want to. I know on Macs most things go under Applications and to remove them and all there data you just drag it to trash. I’m hoping that these items (like node.js, cordova/ionic command line tools, etc…) work the same way when it comes to removal. Guess I’ll research it some more later. It is not stopping me from proceeding though, I’m pumped about learning Ionic+Angular. Thanks.


#4

Sooner or later you’ll need to get acquainted with the command line / terminal and tools specific to your development environment and frameworks of choice.

Ionic and Cordova are and should be installed as npm packages.
And to be more specific… Do install nvm, because it will set up both node and npm for you (follow the instructions at the link I already provided). All further installations of both global and local npm packages will be under the “hat” of nvm.
If you ever need to do a cleanup, you can start by reading here for example: https://github.com/creationix/nvm/issues/298

And forget about drag and drop if you’re gonna work with Node, mobile apps, web dev etc.

Regards


#5

I share your concerns as well and just went thru the mac install process.

After installing and accepting default locations, node,npm,ionic, & cordova are all installed in /usr/local/lib.

The commands are symbolic links in the /usr/local/bin directory.

You will need root access to install. That may be a seperate task to setup on a mac.

After you install from the bash command line with root priviledge. type ‘node -v’ or ‘npm -v’ to verify


#6

I’ve been down that road. It’s just fine in most cases and you can avoid or surpass root access related issues. But now and then it gets annoying.
It was one of the main reasons for suggesting NVM, as it installs and keeps everything under your home folder structure. And of course, it makes moving forward (or backwards) in Node versions a breeze. Given my experience with it I doubt I’ll go back to installing/upgrading/managing Node according to the official/classical method.


#7

Hello guys, Please I have been having issues installing ionic. Cordova installed perfectly, I am using a Win8 OS, Nodejs V6.9.1, npm v3.10.8. I have done a npm cache clean. Here is the error log:

82953 warn optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.0.15 (node_modules\ionic\node_modules\ionic-app-lib\node_modules\glob-watcher\node_modules\chokidar\node_modules\fsevents):
82954 warn notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.0.15: wanted {“os”:“darwin”,“arch”:“any”} (current: {“os”:“win32”,“arch”:“x64”})
82955 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Valid OS: darwin
82955 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Valid Arch: any
82955 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Actual OS: win32
82955 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Actual Arch: x64
82956 verbose stack Error: ENOENT: no such file or directory, rename ‘C:\Users\HP 655\AppData\Roaming\npm\node_modules.staging\noptify-491acce8’ -> 'C:\Users\HP 655\AppData\Roaming\npm\node_modules\ionic\node_modules\ionic-app-lib\node_modules\tiny-lr-fork\node_modules\noptify’
82956 verbose stack at whenOldMovedAway (C:\Program Files\nodejs\node_modules\npm\lib\install\action\finalize.js:43:5)
82956 verbose stack at C:\Program Files\nodejs\node_modules\npm\lib\utils\rename.js:13:14
82956 verbose stack at CB (C:\Program Files\nodejs\node_modules\npm\node_modules\graceful-fs\polyfills.js:85:17)
82956 verbose stack at FSReqWrap.oncomplete (fs.js:123:15)
82956 verbose stack
82956 verbose stack Error: ENOENT: no such file or directory, rename ‘C:\Users\HP 655\AppData\Roaming\npm\node_modules.staging\noptify-491acce8’ -> 'C:\Users\HP 655\AppData\Roaming\npm\node_modules\ionic\node_modules\ionic-app-lib\node_modules\tiny-lr-fork\node_modules\noptify’
82956 verbose stack at Error (native)
82957 verbose cwd C:\Users\HP 655
82958 error Windows_NT 6.2.9200
82959 error argv “C:\Program Files\nodejs\node.exe” “C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js” “install” “-g” "ionic"
82960 error node v6.9.1
82961 error npm v3.10.8
82962 error path C:\Users\HP 655\AppData\Roaming\npm\node_modules.staging\noptify-491acce8
82963 error code ENOENT
82964 error errno -4058
82965 error syscall rename
82966 error enoent ENOENT: no such file or directory, rename ‘C:\Users\HP 655\AppData\Roaming\npm\node_modules.staging\noptify-491acce8’ -> 'C:\Users\HP 655\AppData\Roaming\npm\node_modules\ionic\node_modules\ionic-app-lib\node_modules\tiny-lr-fork\node_modules\noptify’
82967 error enoent ENOENT: no such file or directory, rename ‘C:\Users\HP 655\AppData\Roaming\npm\node_modules.staging\noptify-491acce8’ -> 'C:\Users\HP 655\AppData\Roaming\npm\node_modules\ionic\node_modules\ionic-app-lib\node_modules\tiny-lr-fork\node_modules\noptify’
82967 error enoent This is most likely not a problem with npm itself
82967 error enoent and is related to npm not being able to find a file.
82968 verbose exit [ -4058, true ]

Thanks in advance