We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b667f12 commit 6def3bfCopy full SHA for 6def3bf
cli/src/index.ts
@@ -715,6 +715,19 @@ yargs(hideBin(process.argv))
715
const keypair = Keypair.fromSecretKey(new Uint8Array(JSON.parse(fs.readFileSync(argv["keypair"]).toString())));
716
console.log(encoding.b58.encode(keypair.secretKey));
717
})
718
+ .command("token-authority <programId>",
719
+ "print the token authority address for a given program ID",
720
+ (yargs) => yargs
721
+ .positional("programId", {
722
+ describe: "Program ID",
723
+ type: "string",
724
+ demandOption: true,
725
+ }),
726
+ (argv) => {
727
+ const programId = new PublicKey(argv["programId"]);
728
+ const tokenAuthority = NTT.pdas(programId).tokenAuthority();
729
+ console.log(tokenAuthority.toBase58());
730
+ })
731
.demandCommand()
732
}
733
)
0 commit comments