diff options
author | Drew DeVault <sir@cmpwn.com> | 2019-05-19 18:23:34 -0400 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2019-05-19 18:23:34 -0400 |
commit | 455c6f0b774bb5e37906dd3fb8c786892f0b1519 (patch) | |
tree | 2686c0c29238ab2822d6aec3f1c28cba85deb89b | |
parent | fa5d8d7a007aa0030a4b2bfb122dabab3e69ad4b (diff) | |
download | aerc-455c6f0b774bb5e37906dd3fb8c786892f0b1519.tar.gz |
Rename :delete-message et al to :delete et al
-rw-r--r-- | commands/account/delete.go (renamed from commands/account/delete-message.go) | 3 | ||||
-rw-r--r-- | commands/account/next.go (renamed from commands/account/next-message.go) | 4 | ||||
-rw-r--r-- | commands/account/select.go (renamed from commands/account/select-message.go) | 0 | ||||
-rw-r--r-- | commands/account/view.go (renamed from commands/account/view-message.go) | 1 | ||||
-rw-r--r-- | config/binds.conf | 28 |
5 files changed, 20 insertions, 16 deletions
diff --git a/commands/account/delete-message.go b/commands/account/delete.go index d6b669e..65d6eb9 100644 --- a/commands/account/delete-message.go +++ b/commands/account/delete.go @@ -11,12 +11,13 @@ import ( ) func init() { + register("delete", DeleteMessage) register("delete-message", DeleteMessage) } func DeleteMessage(aerc *widgets.Aerc, args []string) error { if len(args) != 1 { - return errors.New("Usage: :delete-message") + return errors.New("Usage: :delete") } acct := aerc.SelectedAccount() if acct == nil { diff --git a/commands/account/next-message.go b/commands/account/next.go index f13ea5a..7e8541f 100644 --- a/commands/account/next-message.go +++ b/commands/account/next.go @@ -10,7 +10,9 @@ import ( ) func init() { + register("next", NextPrevMessage) register("next-message", NextPrevMessage) + register("prev", NextPrevMessage) register("prev-message", NextPrevMessage) } @@ -45,7 +47,7 @@ func NextPrevMessage(aerc *widgets.Aerc, args []string) error { n = int(float64(acct.Messages().Height()) * (float64(n) / 100.0)) } for ; n > 0; n-- { - if args[0] == "prev-message" { + if args[0] == "prev-message" || args[0] == "prev" { acct.Messages().Prev() } else { acct.Messages().Next() diff --git a/commands/account/select-message.go b/commands/account/select.go index bd44c1b..bd44c1b 100644 --- a/commands/account/select-message.go +++ b/commands/account/select.go diff --git a/commands/account/view-message.go b/commands/account/view.go index 4db5c95..40abec3 100644 --- a/commands/account/view-message.go +++ b/commands/account/view.go @@ -7,6 +7,7 @@ import ( ) func init() { + register("view", ViewMessage) register("view-message", ViewMessage) } diff --git a/config/binds.conf b/config/binds.conf index 4d184fb..058b2d0 100644 --- a/config/binds.conf +++ b/config/binds.conf @@ -8,26 +8,26 @@ [messages] q = :quit<Enter> -j = :next-message<Enter> -<Down> = :next-message<Enter> -<C-d> = :next-message 50%<Enter> -<C-f> = :next-message 100%<Enter> -<PgDn> = :next-message -s 100%<Enter> +j = :next<Enter> +<Down> = :next<Enter> +<C-d> = :next 50%<Enter> +<C-f> = :next 100%<Enter> +<PgDn> = :next -s 100%<Enter> -k = :prev-message<Enter> -<Up> = :prev-message<Enter> -<C-u> = :prev-message 50%<Enter> -<C-b> = :prev-message 100%<Enter> -<PgUp> = :prev-message -s 100%<Enter> -g = :select-message 0<Enter> -G = :select-message -1<Enter> +k = :prev<Enter> +<Up> = :prev<Enter> +<C-u> = :prev 50%<Enter> +<C-b> = :prev 100%<Enter> +<PgUp> = :prev -s 100%<Enter> +g = :select 0<Enter> +G = :select -1<Enter> J = :next-folder<Enter> K = :prev-folder<Enter> -<Enter> = :view-message<Enter> +<Enter> = :view<Enter> d = :confirm 'Really delete this message?' ':delete-message<Enter>'<Enter> -D = :delete-message<Enter> +D = :delete<Enter> rr = :reply<Enter> rq = :reply -q<Enter> |