Skip to content

Commit

Permalink
chore: 🤖 add help subcommand and description for ens
Browse files Browse the repository at this point in the history
  • Loading branch information
heldrida committed Sep 19, 2024
1 parent 296e73f commit cbc20b5
Showing 1 changed file with 13 additions and 7 deletions.
20 changes: 13 additions & 7 deletions src/commands/ens/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@ export default (program: Command) => {
const cmd = program
.command('ens')
.option('-h, --help', t('printHelp'))
.description(t('ensCmdDescription'));

.description(t('ensCmdDescription'))
.addHelpCommand();

cmd
.command('create')
.option('--siteId <string>', t('siteIdOf'))
Expand All @@ -27,7 +28,8 @@ export default (program: Command) => {
name?: string;
ipns?: string;
}) => createEnsActionHandler(options),
);
)
.addHelpCommand();

cmd
.command('detail')
Expand All @@ -42,15 +44,17 @@ export default (program: Command) => {
.description(t('ensShowDetails'))
.action((options: { id?: string; name?: string }) =>
detailEnsRecordsActionHandler(options),
);
)
.addHelpCommand();

cmd
.command('list')
.option('--siteId <string>', t('siteIdOf'))
.description(t('ensListAllForProject'))
.action((options: { siteId?: string }) =>
listEnsRecordsActionHandler(options),
);
)
.addHelpCommand();

cmd
.command('delete')
Expand All @@ -73,7 +77,8 @@ export default (program: Command) => {
.description(t('ensDelete'))
.action((options: { id?: string; name?: string }) =>
deleteEnsActionHandler(options),
);
)
.addHelpCommand();

cmd
.command('verify')
Expand All @@ -96,7 +101,8 @@ export default (program: Command) => {
.description(t('ensVerifyIsConfig'))
.action((options: { id?: string; name?: string }) =>
verifyEnsRecordActionHandler(options),
);
)
.addHelpCommand();

cmd.command('help').description(t('printHelp'));
};

0 comments on commit cbc20b5

Please sign in to comment.