From 0091851ef716c7148581a955fbd70ed3b45ef3ae Mon Sep 17 00:00:00 2001 From: Julien Robert Date: Mon, 11 Mar 2024 11:51:12 +0100 Subject: [PATCH] feat(x/distribution): add rewards-by-validator autocli config (#19707) --- x/distribution/autocli.go | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/x/distribution/autocli.go b/x/distribution/autocli.go index fbfde063d93..c53abc4eda4 100644 --- a/x/distribution/autocli.go +++ b/x/distribution/autocli.go @@ -61,15 +61,24 @@ func (am AppModule) AutoCLIOptions() *autocliv1.ModuleOptions { }, { RpcMethod: "DelegationRewards", - Use: "rewards [delegator-addr] [validator-addr]", - Short: "Query all distribution delegator rewards or rewards from a particular validator", - Long: "Query all rewards earned by a delegator, optionally restrict to rewards from a single validator.", + Use: "rewards-by-validator [delegator-addr] [validator-addr]", + Short: "Query all distribution delegator from a particular validator", Example: fmt.Sprintf("$ %s query distribution rewards [delegator-address] [validator-address]", version.AppName), PositionalArgs: []*autocliv1.PositionalArgDescriptor{ {ProtoField: "delegator_address"}, {ProtoField: "validator_address"}, }, }, + { + RpcMethod: "DelegationTotalRewards", + Use: "rewards [delegator-addr]", + Short: "Query all distribution delegator rewards", + Long: "Query all rewards earned by a delegator", + Example: fmt.Sprintf("$ %s query distribution rewards [delegator-address]", version.AppName), + PositionalArgs: []*autocliv1.PositionalArgDescriptor{ + {ProtoField: "delegator_address"}, + }, + }, { RpcMethod: "CommunityPool", Use: "community-pool",