Azure CLI – Uninstall & Install

It’s not really important post and the post title sounds weird :) But it’s important for me as my note.

Today I stumbled upon Azure CLI installation in my Mac machine when trying to repair permissions on /usr/local. I know that’s based on Node.js and it seems the installation has its own Node runtime in it. Hey, I already have latest Node.js runtime installed on my machine. Why need another one.

So I decide to uninstall the “standalone” Azure CLI, and decide to install it using NPM. To uninstall, you can just run this command on Terminal:

To install it again using NPM, type on Terminal:

That’s it!

A bit trick I found. If you uninstall and install using the same Terminal window, make sure to quit that Terminal window first. Open new Terminal window, type: azure –version, and you should see the version of Azure CLI.