Skip to content
This repository was archived by the owner on Feb 12, 2024. It is now read-only.

Commit 924690e

Browse files
author
Alan Shaw
authored
fix: name resolve arg parsing (#1958)
Boolean args were not being parsed as booleans. License: MIT Signed-off-by: Alan Shaw <[email protected]>
1 parent 3b91ea1 commit 924690e

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

src/cli/commands/daemon.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ module.exports = {
2020
default: false
2121
})
2222
.option('offline', {
23+
type: 'boolean',
2324
desc: 'Run offline. Do not connect to the rest of the network but provide local API.',
2425
default: false
2526
})

src/cli/commands/name/resolve.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,15 @@ module.exports = {
99

1010
builder: {
1111
nocache: {
12+
type: 'boolean',
1213
alias: 'n',
1314
describe: 'Do not use cached entries. Default: false.',
1415
default: false
1516
},
1617
recursive: {
18+
type: 'boolean',
1719
alias: 'r',
18-
recursive: 'Resolve until the result is not an IPNS name. Default: false.',
20+
describe: 'Resolve until the result is not an IPNS name. Default: false.',
1921
default: false
2022
}
2123
},

test/cli/name.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,7 @@ describe('name', () => {
158158
})
159159
})
160160

161-
// FIXME: currently failing, resolve before 0.35 release!
162-
it.skip('should go recursively until finding an ipfs hash', function () {
161+
it('should go recursively until finding an ipfs hash', function () {
163162
this.timeout(90 * 1000)
164163

165164
return ipfs(`name publish ${cidAdded}`)

0 commit comments

Comments
 (0)