@thi.ng/args
Advanced tools
Comparing version
# Change Log | ||
- **Last updated**: 2022-03-11T12:13:49Z | ||
- **Last updated**: 2022-04-07T14:17:30Z | ||
- **Generator**: [thi.ng/monopub](https://thi.ng/monopub) | ||
@@ -12,2 +12,8 @@ | ||
### [2.1.6](https://github.com/thi-ng/umbrella/tree/@thi.ng/args@2.1.6) (2022-04-07) | ||
#### ♻️ Refactoring | ||
- replace deprecated .substr() w/ .substring() ([0710509](https://github.com/thi-ng/umbrella/commit/0710509)) | ||
## [2.1.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/args@2.1.0) (2021-11-17) | ||
@@ -14,0 +20,0 @@ |
@@ -23,4 +23,4 @@ import { isHex } from "@thi.ng/checks/is-hex"; | ||
if (idx > 0) { | ||
const id = x.substr(0, idx); | ||
const val = x.substr(idx + 1); | ||
const id = x.substring(0, idx); | ||
const val = x.substring(idx + 1); | ||
if (multi) { | ||
@@ -27,0 +27,0 @@ acc[id] ? acc[id].push(val) : (acc[id] = [val]); |
{ | ||
"name": "@thi.ng/args", | ||
"version": "2.1.5", | ||
"version": "2.1.6", | ||
"description": "Declarative, functional & typechecked CLI argument/options parser, value coercions etc.", | ||
@@ -37,10 +37,10 @@ "type": "module", | ||
"dependencies": { | ||
"@thi.ng/api": "^8.3.4", | ||
"@thi.ng/checks": "^3.1.4", | ||
"@thi.ng/errors": "^2.1.4", | ||
"@thi.ng/strings": "^3.3.2" | ||
"@thi.ng/api": "^8.3.5", | ||
"@thi.ng/checks": "^3.1.5", | ||
"@thi.ng/errors": "^2.1.5", | ||
"@thi.ng/strings": "^3.3.3" | ||
}, | ||
"devDependencies": { | ||
"@microsoft/api-extractor": "^7.19.4", | ||
"@thi.ng/testament": "^0.2.4", | ||
"@thi.ng/testament": "^0.2.5", | ||
"rimraf": "^3.0.2", | ||
@@ -79,18 +79,18 @@ "tools": "^0.0.1", | ||
".": { | ||
"import": "./index.js" | ||
"default": "./index.js" | ||
}, | ||
"./api": { | ||
"import": "./api.js" | ||
"default": "./api.js" | ||
}, | ||
"./args": { | ||
"import": "./args.js" | ||
"default": "./args.js" | ||
}, | ||
"./coerce": { | ||
"import": "./coerce.js" | ||
"default": "./coerce.js" | ||
}, | ||
"./parse": { | ||
"import": "./parse.js" | ||
"default": "./parse.js" | ||
}, | ||
"./usage": { | ||
"import": "./usage.js" | ||
"default": "./usage.js" | ||
} | ||
@@ -101,3 +101,3 @@ }, | ||
}, | ||
"gitHead": "0fc692a3225c068aacafdc4cb6140cf603c67ad8\n" | ||
"gitHead": "5ee1feb590dd935593b1dd4e7f38a3ed3ba64765\n" | ||
} |
@@ -60,6 +60,6 @@ import { isArray } from "@thi.ng/checks/is-array"; | ||
return { state: 1 }; | ||
id = camel(a.substr(2)); | ||
id = camel(a.substring(2)); | ||
} | ||
else { | ||
id = aliases[a.substr(1)]; | ||
id = aliases[a.substring(1)]; | ||
!id && illegalArgs(`unknown option: ${a}`); | ||
@@ -66,0 +66,0 @@ } |
58400
0.41%Updated
Updated
Updated
Updated