aboutsummaryrefslogtreecommitdiff
path: root/commands/new-account.go
diff options
context:
space:
mode:
Diffstat (limited to 'commands/new-account.go')
-rw-r--r--commands/new-account.go14
1 files changed, 12 insertions, 2 deletions
diff --git a/commands/new-account.go b/commands/new-account.go
index 9e70dec..8d2fef5 100644
--- a/commands/new-account.go
+++ b/commands/new-account.go
@@ -7,11 +7,21 @@ import (
"git.sr.ht/~sircmpwn/getopt"
)
+type NewAccount struct{}
+
func init() {
- register("new-account", CommandNewAccount)
+ register(NewAccount{})
+}
+
+func (_ NewAccount) Aliases() []string {
+ return []string{"new-account"}
+}
+
+func (_ NewAccount) Complete(aerc *widgets.Aerc, args []string) []string {
+ return nil
}
-func CommandNewAccount(aerc *widgets.Aerc, args []string) error {
+func (_ NewAccount) Execute(aerc *widgets.Aerc, args []string) error {
opts, _, err := getopt.Getopts(args, "t")
if err != nil {
return errors.New("Usage: new-account [-t]")