mirror of
https://github.com/QuilibriumNetwork/ceremonyclient.git
synced 2026-03-11 11:18:13 +08:00
* initial auto-update * working link, update, and testing docker container and scripts * refactor packages/folders * move files to proper folders * fix typos Closes #421 * optimize rpm imports * optimize channel imports * Refactor split command to allow testing of split operations Closes #338 * modify split and test for folder changes * remove alias * fix docker warning about FROM and AS being in different letter case Closes #422 * QClient Account Command * Display transaction details and confirmation prompts for transfer and merge commands * build qclient docker improvements * update build args for mpfr.so.6 * update install and node commands * remove NodeConfig check for qclient node commands * udpate * working node commands * update commands * move utils and rename package --------- Co-authored-by: Vasyl Tretiakov <vasyl.tretiakov@gmail.com> Co-authored-by: littleblackcloud <163544315+littleblackcloud@users.noreply.github.com> Co-authored-by: 0xOzgur <29779769+0xOzgur@users.noreply.github.com> Co-authored-by: Cassandra Heart <7929478+CassOnMars@users.noreply.github.com>
29 lines
609 B
Go
29 lines
609 B
Go
package token
|
|
|
|
import (
|
|
"fmt"
|
|
|
|
"github.com/iden3/go-iden3-crypto/poseidon"
|
|
"github.com/spf13/cobra"
|
|
"source.quilibrium.com/quilibrium/monorepo/client/utils"
|
|
)
|
|
|
|
var accountCmd = &cobra.Command{
|
|
Use: "account",
|
|
Short: "Shows the account address of the managing account",
|
|
Run: func(cmd *cobra.Command, args []string) {
|
|
peerId := utils.GetPeerIDFromConfig(NodeConfig)
|
|
addr, err := poseidon.HashBytes([]byte(peerId))
|
|
if err != nil {
|
|
panic(err)
|
|
}
|
|
|
|
addrBytes := addr.FillBytes(make([]byte, 32))
|
|
fmt.Printf("Account: 0x%x\n", addrBytes)
|
|
},
|
|
}
|
|
|
|
func init() {
|
|
TokenCmd.AddCommand(accountCmd)
|
|
}
|