diff options
author | Srivathsan Murali <sri@vathsan.com> | 2019-09-20 21:22:09 +0200 |
---|---|---|
committer | Drew DeVault <sir@cmpwn.com> | 2019-09-20 15:23:45 -0400 |
commit | 1bedb8fe06dd71b4ee044098b7f057b3bffd0efc (patch) | |
tree | 5587d2ffe4af714533442b52f848f60284bf9d63 /config | |
parent | 043a02d99d93441021788891d3f86c6fdeea22f0 (diff) | |
download | aerc-1bedb8fe06dd71b4ee044098b7f057b3bffd0efc.tar.gz |
Config for deleting message from message viewer
As suggested in #268, this adds a behaviour setting for deleting message from message viewer.
Diffstat (limited to 'config')
-rw-r--r-- | config/aerc.conf.in | 5 | ||||
-rw-r--r-- | config/config.go | 50 |
2 files changed, 31 insertions, 24 deletions
diff --git a/config/aerc.conf.in b/config/aerc.conf.in index 9ad7fcd..ec89ff7 100644 --- a/config/aerc.conf.in +++ b/config/aerc.conf.in @@ -57,6 +57,11 @@ dirlist-format=%n %>r # Default: "" sort= +# Moves to next message when the current message is deleted +# +# Default: false +next-message-on-delete=true + [viewer] # # Specifies the pager to use when displaying emails. Note that some filters diff --git a/config/config.go b/config/config.go index 5a41903..133a7f4 100644 --- a/config/config.go +++ b/config/config.go @@ -23,20 +23,21 @@ type GeneralConfig struct { } type UIConfig struct { - IndexFormat string `ini:"index-format"` - TimestampFormat string `ini:"timestamp-format"` - ShowHeaders []string `delim:","` - RenderAccountTabs string `ini:"render-account-tabs"` - SidebarWidth int `ini:"sidebar-width"` - PreviewHeight int `ini:"preview-height"` - EmptyMessage string `ini:"empty-message"` - EmptyDirlist string `ini:"empty-dirlist"` - MouseEnabled bool `ini:"mouse-enabled"` - NewMessageBell bool `ini:"new-message-bell"` - Spinner string `ini:"spinner"` - SpinnerDelimiter string `ini:"spinner-delimiter"` - DirListFormat string `ini:"dirlist-format"` - Sort []string `delim:" "` + IndexFormat string `ini:"index-format"` + TimestampFormat string `ini:"timestamp-format"` + ShowHeaders []string `delim:","` + RenderAccountTabs string `ini:"render-account-tabs"` + SidebarWidth int `ini:"sidebar-width"` + PreviewHeight int `ini:"preview-height"` + EmptyMessage string `ini:"empty-message"` + EmptyDirlist string `ini:"empty-dirlist"` + MouseEnabled bool `ini:"mouse-enabled"` + NewMessageBell bool `ini:"new-message-bell"` + Spinner string `ini:"spinner"` + SpinnerDelimiter string `ini:"spinner-delimiter"` + DirListFormat string `ini:"dirlist-format"` + Sort []string `delim:" "` + NextMessageOnDelete bool `ini:"next-message-on-delete"` } const ( @@ -346,16 +347,17 @@ func LoadConfigFromFile(root *string, sharedir string) (*AercConfig, error) { ShowHeaders: []string{ "From", "To", "Cc", "Bcc", "Subject", "Date", }, - RenderAccountTabs: "auto", - SidebarWidth: 20, - PreviewHeight: 12, - EmptyMessage: "(no messages)", - EmptyDirlist: "(no folders)", - MouseEnabled: false, - NewMessageBell: true, - Spinner: "[..] , [..] , [..] , [..] , [..], [..] , [..] , [..] ", - SpinnerDelimiter: ",", - DirListFormat: "%n %>r", + RenderAccountTabs: "auto", + SidebarWidth: 20, + PreviewHeight: 12, + EmptyMessage: "(no messages)", + EmptyDirlist: "(no folders)", + MouseEnabled: false, + NewMessageBell: true, + Spinner: "[..] , [..] , [..] , [..] , [..], [..] , [..] , [..] ", + SpinnerDelimiter: ",", + DirListFormat: "%n %>r", + NextMessageOnDelete: true, }, Viewer: ViewerConfig{ |