-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.go
35 lines (31 loc) · 827 Bytes
/
main.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
package main
import (
"context"
"fmt"
"os"
"github.com/urfave/cli/v3"
"github.com/volodymyrprokopyuk/go-wallet/crypto"
"github.com/volodymyrprokopyuk/go-wallet/hdwallet"
)
func walletCmd() *cli.Command {
cmd := &cli.Command{
Name: "wallet",
Usage: "EC keys and signatures, a HD wallet, cryptographic functions",
Version: "0.1.0",
Commands: []*cli.Command{
hdwallet.ECKeyCmd(), hdwallet.ECDSACmd(), hdwallet.AddressCmd(),
hdwallet.MnemonicCmd(), hdwallet.HDCmd(),
crypto.SHA256Cmd(), crypto.Keccak256Cmd(),
crypto.HMACSHA512Cmd(), crypto.PBKDF2SHA512Cmd(),
crypto.Base58Cmd(), crypto.Base58CheckCmd(),
},
}
return cmd
}
func main() {
err := walletCmd().Run(context.Background(), os.Args)
if err != nil {
fmt.Fprintln(os.Stderr, err)
os.Exit(1)
}
}