From 37e47924261cf968b93f67d798be064e93251325 Mon Sep 17 00:00:00 2001 From: Alex Guerra Date: Thu, 12 Dec 2019 18:00:41 -0600 Subject: [PATCH] Add current version and bin location to --info output Make the --info subcommand outuput the current version information and the location of the file being run. Our issue template tells users to provide the output of --info, so having the current version is incredibly helpful, especially since it doesn't necessarily match the globally installed version that envinfo outputs. Knowing the location helps us determine whether the running bin is globally installed or in the local node_modules. --- packages/create-react-app/createReactApp.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/create-react-app/createReactApp.js b/packages/create-react-app/createReactApp.js index d8571d8518b..f39b0f6af9e 100755 --- a/packages/create-react-app/createReactApp.js +++ b/packages/create-react-app/createReactApp.js @@ -156,6 +156,10 @@ const program = new commander.Command(packageJson.name) if (program.info) { console.log(chalk.bold('\nEnvironment Info:')); + console.log( + `\n current version of ${packageJson.name}: ${packageJson.version}` + ); + console.log(` running from ${__dirname}`); return envinfo .run( {