Skip to content

Commit f91e235

Browse files
committed
Minor improvements
1 parent 1ddb44b commit f91e235

File tree

2 files changed

+12
-4
lines changed

2 files changed

+12
-4
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"name": "npm-ri",
44
"private": false,
55
"description": "npm install packages using regular expressions to update installed dependencies",
6-
"version": "0.0.5",
6+
"version": "0.0.6",
77
"author": "Danilo Britto",
88
"repository": {
99
"type": "git",

src/index.ts

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,13 +73,21 @@ function run(
7373
return;
7474
}
7575

76-
throw new Error("Something went wrong");
76+
program.error("Something went wrong");
7777
});
7878

7979
return;
8080
}
8181

82-
throw new Error(
82+
if (dryRun) {
83+
console.warn(
84+
`No packages found with the next regular expressions: ${dependencyNameRegex}`
85+
);
86+
87+
return;
88+
}
89+
90+
program.error(
8391
`No packages found with the next regular expressions: ${dependencyNameRegex}`
8492
);
8593
}
@@ -89,7 +97,7 @@ program
8997
.description(
9098
"npm install using regular expressions to update installed dependencies"
9199
)
92-
.version("0.0.5");
100+
.version("0.0.6");
93101

94102
program
95103
.argument(

0 commit comments

Comments
 (0)