@koalarx/nest-cli 1.2.11 → 1.2.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
File without changes
package/index.ts CHANGED
@@ -2,11 +2,15 @@
2
2
 
3
3
  import program from 'commander'
4
4
  import inquirer from 'inquirer'
5
- import packageJson from '../package.json'
5
+ import { readFileSync } from 'fs'
6
+ import path from 'path'
6
7
  import { newProject } from './commands/new-project'
7
8
  import chalk from 'chalk'
8
9
  import figlet from 'figlet'
9
10
 
11
+ const packageJsonPath = path.join(__dirname, '../package.json')
12
+ const packageJson = JSON.parse(readFileSync(packageJsonPath, 'utf8'))
13
+
10
14
  program.version(packageJson.version)
11
15
 
12
16
  console.log(chalk.cyan(figlet.textSync('Koala Nest CLI')))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@koalarx/nest-cli",
3
- "version": "1.2.11",
3
+ "version": "1.2.13",
4
4
  "description": "Biblioteca de CLI para criação de projetos utilizando Koala Nest",
5
5
  "scripts": {
6
6
  "test": "vitest run",
@@ -18,7 +18,7 @@
18
18
  },
19
19
  "main": "dist/index.ts",
20
20
  "bin": {
21
- "koala-nest": "commands/new-project/index.ts"
21
+ "koala-nest": "index.ts"
22
22
  },
23
23
  "repository": {
24
24
  "type": "git",