nearprotocol

Command 'near' not found


I am using these instructions to generate public and private keys for an account (testnet) to do some test transactions.

https://docs.near.org/docs/tokens/token-custody#option-2-self-custody

I run this command on terminal

npm install -g near-cli

and then this command to generate the key

near generate-key dummyaccount.testnet

but it says

Command 'near' not found

any idea what am I missing here (sorry just got started with this thing).

npm 7.23.0 node 12.18.2


Solution

  • Have you done this?:

    “If Node modules are installed in a place inaccessible by your OS user, you need to do chown -R $USER /path/to/destination/ or the equivalent on your OS.”

    https://docs.near.org/docs/tokens/token-custody#to-generate-public-keys-via-cli