diff --git a/README.md b/README.md index 4a8490c6..87decb50 100644 --- a/README.md +++ b/README.md @@ -1,16 +1,16 @@ -# NEAR Shell command line interface +# NEAR CLI (command line interface) [![Build Status](https://travis-ci.com/near/near-shell.svg?branch=master)](https://travis-ci.com/near/near-shell) [![Gitpod Ready-to-Code](https://img.shields.io/badge/Gitpod-Ready--to--Code-blue?logo=gitpod)](https://gitpod.io/#https://github.com/near/near-shell) -NEAR Shell is a Node.js application that relies on [`near-api-js`](https://github.com/near/near-api-js) to generate secure keys, connect to the NEAR platform and send transactions to the network on your behalf. +NEAR CLI is a Node.js application that relies on [`near-api-js`](https://github.com/near/near-api-js) to generate secure keys, connect to the NEAR platform and send transactions to the network on your behalf. -> note that **Node.js version 10+** is required to run NEAR Shell +> note that **Node.js version 10+** is required to run NEAR CLI ## Installation ```bash -npm install -g near-shell +npm install -g near-cli ``` ## Usage diff --git a/commands/dev-deploy.js b/commands/dev-deploy.js index 8b68d4d0..aa4274b0 100644 --- a/commands/dev-deploy.js +++ b/commands/dev-deploy.js @@ -54,7 +54,7 @@ async function devDeploy(options) { async function createDevAccountIfNeeded({ near, keyStore, networkId, init, masterAccount }) { // TODO: once examples and create-near-app use the dev-account.env file, we can remove the creation of dev-account - // https://github.com/nearprotocol/near-shell/issues/287 + // https://github.com/near/near-shell/issues/287 const accountFilePath = `${PROJECT_KEY_DIR}/dev-account`; const accountFilePathEnv = `${PROJECT_KEY_DIR}/dev-account.env`; if (!init) { diff --git a/index.js b/index.js index fc8f8106..3b3c11ae 100644 --- a/index.js +++ b/index.js @@ -80,12 +80,12 @@ exports.login = async function (options) { await eventtracking.track(eventtracking.EVENT_ID_LOGIN_END, { success: true, login_is_not_needed: true }, options); } else { const newUrl = new URL(options.walletUrl + '/login/'); - const title = 'NEAR Shell'; + const title = 'NEAR CLI'; newUrl.searchParams.set('title', title); const keyPair = await KeyPair.fromRandom('ed25519'); newUrl.searchParams.set('public_key', keyPair.getPublicKey()); - console.log(chalk`\n{bold.yellow Please authorize NEAR Shell} on at least one of your accounts.`); + console.log(chalk`\n{bold.yellow Please authorize NEAR CLI} on at least one of your accounts.`); // attempt to capture accountId automatically via browser callback let tempUrl; @@ -134,7 +134,7 @@ exports.login = async function (options) { return await new Promise((resolve) => { rl.question( chalk`Please authorize at least one account at the URL above.\n\n` + - chalk`Which account did you authorize for use with NEAR Shell?\n` + + chalk`Which account did you authorize for use with NEAR CLI?\n` + chalk`{bold Enter it here${redirectAutomaticallyHint}:}\n`, async (accountId) => { resolve(accountId); }); diff --git a/package.json b/package.json index 391018fd..c79b363c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { - "name": "near-shell", - "version": "0.24.9", + "name": "near-cli", + "version": "1.0.0", "description": "General purpose command line tools for interacting with NEAR Protocol", "engines": { "node": ">= 10" @@ -13,14 +13,14 @@ }, "repository": { "type": "git", - "url": "git+https://github.com/nearprotocol/near-shell.git" + "url": "git+https://github.com/near/near-shell.git" }, "author": "Jane Degtiareva", "license": "(MIT AND Apache-2.0)", "bugs": { - "url": "https://github.com/nearprotocol/near-shell/issues" + "url": "https://github.com/near/near-shell/issues" }, - "homepage": "https://github.com/nearprotocol/near-shell#readme", + "homepage": "https://github.com/near/near-shell#readme", "bin": { "near": "./bin/near" }, diff --git a/utils/check-version.js b/utils/check-version.js index 5882d161..a2d691dd 100644 --- a/utils/check-version.js +++ b/utils/check-version.js @@ -11,7 +11,7 @@ const isCI = require('is-ci'); // avoid output if running in CI server const UPDATE_CHECK_INTERVAL_SECONDS = 1; /** - check the current version of NEAR Shell against latest as published on npm + check the current version of NEAR CLI against latest as published on npm */ module.exports = async function checkVersion() { const pkg = require('../package.json'); @@ -26,7 +26,7 @@ module.exports = async function checkVersion() { const { type: diff, current, latest } = notifier.update; const update = normalizePhrasingOf(diff); const updateCommand = '{updateCommand}'; - const message = chalk`NEAR Shell has a ${update} available {dim ${current}} → {green ${latest}} + const message = chalk`NEAR CLI has a ${update} available {dim ${current}} → {green ${latest}} Run {cyan ${updateCommand}} to avoid unexpected behavior`; const boxenOpts = { diff --git a/utils/eventtracking.js b/utils/eventtracking.js index a626b5f7..3594dfd9 100644 --- a/utils/eventtracking.js +++ b/utils/eventtracking.js @@ -64,7 +64,7 @@ const getEventTrackingConsent = async () => { for (let attempts = 0; attempts < 10; attempts++) { const answer = await new Promise((resolve) => { rl.question( - chalk`We would like to collect data on near-shell usage to improve developer experience.` + + chalk`We would like to collect data on near-cli usage to improve developer experience.` + chalk` We will never send private information. We only collect which commands are run via an anonymous identifier.` + chalk`{bold.yellow Would you like to opt in (y/n)? }`, async (consentToEventTracking) => {