failed to install expo cli

Please run expo diagnostics and paste the log that’s printed out along with your question or issue!

input:
expo diagnostics

output:
internal/modules/cjs/loader.js:985
throw err;
^

Error: Cannot find module ‘C:\Users\edmon\AppData\Roaming\npm\node_modules\expo-cli\bin\expo.js’
e[90m at Function.Module._resolveFilename (internal/modules/cjs/loader.js:982:15)e[39m
e[90m at Function.Module._load (internal/modules/cjs/loader.js:864:27)e[39m
e[90m at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:74:12)e[39m
e[90m at internal/main/run_main_module.js:18:47e[39m {
code: e[32m’MODULE_NOT_FOUND’e[39m,
requireStack:

input: npm install -g expo-cli
output:

npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/epo-cli - Not found
npm ERR! 404
npm ERR! 404 ‘epo-cli@latest’ is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or use the name yourself!)
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\edmon\AppData\Roaming\npm-cache_logs\2020-03-17T00_14_26_752Z-debug.log

Hi Everyone,

i m new react native and i have tried to setup environment with expo and android studio emulator but all attempts without success. Not sure what did i do wrong.

Any suggestion is appreciated. thank you in advance.

this looks like a typo:

npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/epo-cli - Not found
npm ERR! 404
npm ERR! 404 ‘epo-cli@latest’ is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or u

notice “epo-cli” rather than “expo-cli”

run npm i -g expo-cli

thank you for your fast reply.
sorry i forgot to mention, i did try with the correct command afterwards:
input: npm install -g expo-cli
output:
npm ERR! code EEXIST
npm ERR! path C:\Users\edmon\AppData\Roaming\npm\node_modules\expo-cli\bin\expo.js
npm ERR! dest C:\Users\edmon\AppData\Roaming\npm\expo.cmd
npm ERR! EEXIST: file already exists, cmd shim ‘C:\Users\edmon\AppData\Roaming\npm\node_modules\expo-cli\bin\expo.js’ -> ‘C:\Users\edmon\AppData\Roaming\npm\expo.cmd’
npm ERR! File exists: C:\Users\edmon\AppData\Roaming\npm\expo.cmd
npm ERR! Remove the existing file and try again, or run npm
npm ERR! with --force to overwrite files recklessly.

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\edmon\AppData\Roaming\npm-cache_logs\2020-03-17T00_19_06_595Z-debug.log

Weird. It seems like it’s an issue with how you have Node/NPM configured. Are you able to install other modules globally?