Skip to content

Commit

Permalink
fix cli boolean arg bug
Browse files Browse the repository at this point in the history
  • Loading branch information
TheKhanj committed Mar 12, 2024
1 parent ed3598a commit 34d9b83
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,10 @@ function parseArgs(): Args | void {
}

const value = o[i + 1];
if (value.startsWith("-")) continue;
if (value.startsWith("-")) {
obj[key] = true;
continue;
}

obj[key] = value;
i++;
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "convconv",
"version": "0.3.5",
"version": "0.3.6",
"description": "Naming Conventions Converter",
"main": "dist/index.js",
"types": "dist/index.d.ts",
Expand Down

0 comments on commit 34d9b83

Please sign in to comment.