Skip to content

Commit

Permalink
Merge pull request #6 from ostrojs/master
Browse files Browse the repository at this point in the history
error fix for check package version when node version change through nvm
  • Loading branch information
amarksingh authored Apr 4, 2023
2 parents a5deeff + ac02c9d commit 1c63e6a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions newCommand.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ class NewCommand extends Command {

let $currentVersion = this.runCommands(['npm show @ostro/installer version'])

let $existingVersion = this.runCommands([`npm ls @ostro/installer -g version --depth=0`])
$existingVersion = $existingVersion.replace(/[\s\S]*?@ostro\/installer@/gi,'');
let $existingVersion = this.runCommands([`npm ls @ostro/installer -g version --depth=0`]);
$existingVersion = ($existingVersion || "").replace(/[\s\S]*?@ostro\/installer@/gi,'');

this.output.write('[1/7] ')
let versionMessage = $existingVersion == $currentVersion ? '@ostro/installer version verified' : `Update require "npm install @ostro/installer@latest -g"`
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
{
"name": "@ostro/installer",
"version": "0.0.0-alpha.4",
"version": "1.0.1",
"description": "OstroJS framework installer",
"dependencies": {
"@ostro/support": "^0.0.0-alpha",
"@ostro/console": "^0.0.0-alpha"
"@ostro/support": "^1.0.6",
"@ostro/console": "^1.0.0"
},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
"test": "echo \"No test specified\""
},
"engines": {
"node": ">=12.0.0"
Expand Down

0 comments on commit 1c63e6a

Please sign in to comment.