Update auth cli commands (#6717)
* add utils * update sign cmd * update multisign cmd * update sign batch cmd * update genutil cmd * add wrap tx builder * update gentx cli * update validate sigs cmd * fix lint * add flag reader to cli * update marshaler for batchscan * add register query server * update to master * remove depricated methods * fix keyring issue * update wraptx * Fix batch scan * fix register interfaces issue * update printOutput * Update Validate Sigs test * WIP on signature JSON * Cleanup * Cleanup * Test fixes * Test fixes * Fixes * WIP on tests * Fix gov tests * fix lint * fix MultiSign tests * fix tests * refactor tests * Cleanup * Address review comments * Update encode * Test fix * Rename SignData func * Fix lint * Fix lint * Revert ReadTxCommandFlags Co-authored-by: Aaron Craelius <aaron@regen.network> Co-authored-by: Aaron Craelius <aaronc@users.noreply.github.com>
This commit is contained in:
co-authored by
Aaron Craelius
Aaron Craelius
parent
cf078c0c88
commit
72ebafeeca
@@ -2,6 +2,7 @@ package cli
|
||||
|
||||
import (
|
||||
"encoding/base64"
|
||||
"fmt"
|
||||
|
||||
"github.com/spf13/cobra"
|
||||
|
||||
@@ -10,13 +11,6 @@ import (
|
||||
authclient "github.com/cosmos/cosmos-sdk/x/auth/client"
|
||||
)
|
||||
|
||||
// txEncodeRespStr implements a simple Stringer wrapper for a encoded tx.
|
||||
type txEncodeRespStr string
|
||||
|
||||
func (txr txEncodeRespStr) String() string {
|
||||
return string(txr)
|
||||
}
|
||||
|
||||
// GetEncodeCommand returns the encode command to take a JSONified transaction and turn it into
|
||||
// Amino-serialized bytes
|
||||
func GetEncodeCommand() *cobra.Command {
|
||||
@@ -44,8 +38,7 @@ If you supply a dash (-) argument in place of an input filename, the command rea
|
||||
// base64 encode the encoded tx bytes
|
||||
txBytesBase64 := base64.StdEncoding.EncodeToString(txBytes)
|
||||
|
||||
response := txEncodeRespStr(txBytesBase64)
|
||||
return clientCtx.PrintOutput(response)
|
||||
return clientCtx.PrintString(fmt.Sprintf("%s\n", txBytesBase64))
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user