Compare commits

...
3 Commits
Author SHA1 Message Date
telackey f3c0ae8c34 Use SDK 0.1.10 (#44)
Reviewed-on: cerc-io/laconic-registry-cli#44
Co-authored-by: Thomas E Lackey <telackey@bozemanpass.com>
Co-committed-by: Thomas E Lackey <telackey@bozemanpass.com>
2023-12-07 22:15:04 +00:00
telackey f5625d0c87 Take the path as-is, not relative to the current dir. (#43)
Reviewed-on: cerc-io/laconic-registry-cli#43
Co-authored-by: Thomas E Lackey <telackey@bozemanpass.com>
Co-committed-by: Thomas E Lackey <telackey@bozemanpass.com>
2023-12-05 03:53:15 +00:00
telackey fb381c07f3 Fix cns name resolve (#42)
The `cns name resolve` does not return the result.  Obviously it should.

Reviewed-on: cerc-io/laconic-registry-cli#42
Co-authored-by: Thomas E Lackey <telackey@bozemanpass.com>
Co-committed-by: Thomas E Lackey <telackey@bozemanpass.com>
2023-11-30 05:01:25 +00:00
5 changed files with 13 additions and 13 deletions
+2 -2
View File
@@ -1,6 +1,6 @@
{
"name": "@cerc-io/laconic-registry-cli",
"version": "0.1.2",
"version": "0.1.4",
"main": "index.js",
"repository": "git@github.com:cerc-io/laconic-registry-cli.git",
"author": "",
@@ -15,7 +15,7 @@
},
"dependencies": {
"fs-extra": "^10.1.0",
"@cerc-io/laconic-sdk": "0.1.9",
"@cerc-io/laconic-sdk": "^0.1.10",
"js-yaml": "^3.14.1",
"lodash": "^4.17.21",
"lodash-clean": "^2.2.3",
+4 -4
View File
@@ -2,7 +2,7 @@ import { Arguments } from 'yargs';
import assert from 'assert';
import { Registry } from '@cerc-io/laconic-sdk';
import { getConfig, getConnectionInfo,txOutput } from '../../../util';
import { getConfig, getConnectionInfo, queryOutput } from '../../../util';
export const command = 'resolve [name]';
@@ -20,8 +20,8 @@ export const handler = async (argv: Arguments) => {
const registry = new Registry(gqlEndpoint, restEndpoint, chainId);
const result = await registry.resolveNames([name]);
const success = `{"success":${result.code==0}}`
txOutput(result,success,argv.output,argv.verbose)
let result = await registry.resolveNames([name]);
result = result.filter((v: any) => v);
queryOutput(result, argv.output);
}
+2 -2
View File
@@ -48,11 +48,11 @@ export const handler = async (argv: Arguments) => {
// Apply ex post filters.
if (bondId) {
result = result.filter(v => v.bondId === bondId);
result = result.filter((v: any) => v.bondId === bondId);
}
if (owner) {
result = result.filter(v => v.owners?.find((e: string) => e === owner));
result = result.filter((v: any) => v.owners?.find((e: string) => e === owner));
}
queryOutput(result, argv.output)
+1 -1
View File
@@ -30,7 +30,7 @@ export const handler = async (argv: Arguments) => {
let file = null;
if (filename) {
file = path.join(process.cwd(), filename as string);
file = filename as string;
} else {
file = 0; // stdin
}
+4 -4
View File
@@ -2,10 +2,10 @@
# yarn lockfile v1
"@cerc-io/laconic-sdk@0.1.9":
version "0.1.9"
resolved "https://git.vdb.to/api/packages/cerc-io/npm/%40cerc-io%2Flaconic-sdk/-/0.1.9/laconic-sdk-0.1.9.tgz#cf11d20a22c75fd61126640824d27d687f925151"
integrity sha512-LlOBZ39cYalvu9YZBpf5KUkgJJDlsuUhAaBReedwVV5O7zwy+3zRaM4HkX+3saG3a4qR8VfYWEeS5GqF9b6Ixw==
"@cerc-io/laconic-sdk@^0.1.10":
version "0.1.10"
resolved "https://git.vdb.to/api/packages/cerc-io/npm/%40cerc-io%2Flaconic-sdk/-/0.1.10/laconic-sdk-0.1.10.tgz#e706f3ad980df1e27c28dc1729d207b1419c6311"
integrity sha512-vS7WxTpSa7x+uraW920DJV/7MSHxPBKtOFUWg4nj+6r2llx2pCGiVa/FoPQsvLfAPKRy2Uju/I12EhvTYKXqfg==
dependencies:
"@cosmjs/amino" "^0.28.1"
"@cosmjs/crypto" "^0.28.1"