NeoMutt  2021-02-05-89-gabe350
Teaching an old dog new tricks
DOXYGEN
config.c
Go to the documentation of this file.
1 
29 #include "config.h"
30 #include <stddef.h>
31 #include <config/lib.h>
32 #include <stdbool.h>
33 #include "private.h"
34 #include "lib.h"
35 
36 // clang-format off
37 bool C_CheckNew;
39 #ifdef USE_HCACHE
41 #endif
43 bool C_MhPurge;
47 // clang-format on
48 
49 struct ConfigDef MaildirVars[] = {
50  // clang-format off
51  { "check_new", DT_BOOL, &C_CheckNew, true, 0, NULL,
52  "(maildir,mh) Check for new mail while the mailbox is open"
53  },
54  { "maildir_check_cur", DT_BOOL, &C_MaildirCheckCur, false, 0, NULL,
55  "Check both 'new' and 'cur' directories for new mail"
56  },
57 #ifdef USE_HCACHE
58  { "maildir_header_cache_verify", DT_BOOL, &C_MaildirHeaderCacheVerify, true, 0, NULL,
59  "Check for maildir changes when opening mailbox"
60  },
61 #endif
62  { "maildir_trash", DT_BOOL, &C_MaildirTrash, false, 0, NULL,
63  "Use the maildir 'trashed' flag, rather than deleting"
64  },
65  { "mh_purge", DT_BOOL, &C_MhPurge, false, 0, NULL,
66  "Really delete files in MH mailboxes"
67  },
68  { "mh_seq_flagged", DT_STRING, &C_MhSeqFlagged, IP "flagged", 0, NULL,
69  "MH sequence for flagged message"
70  },
71  { "mh_seq_replied", DT_STRING, &C_MhSeqReplied, IP "replied", 0, NULL,
72  "MH sequence to tag replied messages"
73  },
74  { "mh_seq_unseen", DT_STRING, &C_MhSeqUnseen, IP "unseen", 0, NULL,
75  "MH sequence for unseen messages"
76  },
77  { NULL, 0, NULL, 0, 0, NULL, NULL },
78  // clang-format on
79 };
80 
85 {
86  return cs_register_variables(cs, MaildirVars, 0);
87 }
IP
#define IP
Definition: set.h:54
C_MhSeqFlagged
char * C_MhSeqFlagged
Config: MH sequence for flagged message.
Definition: config.c:44
DT_STRING
#define DT_STRING
a string
Definition: types.h:41
C_MhPurge
bool C_MhPurge
Config: Really delete files in MH mailboxes.
Definition: config.c:43
cs_register_variables
bool cs_register_variables(const struct ConfigSet *cs, struct ConfigDef vars[], uint32_t flags)
Register a set of config items.
Definition: set.c:286
C_MaildirHeaderCacheVerify
bool C_MaildirHeaderCacheVerify
Config: (hcache) Check for maildir changes when opening mailbox.
Definition: config.c:40
lib.h
config_init_maildir
bool config_init_maildir(struct ConfigSet *cs)
Register maildir config variables - Implements module_init_config_t.
Definition: config.c:84
MaildirVars
struct ConfigDef MaildirVars[]
Definition: config.c:49
C_CheckNew
bool C_CheckNew
Config: (maildir,mh) Check for new mail while the mailbox is open.
Definition: config.c:37
C_MhSeqUnseen
char * C_MhSeqUnseen
Config: MH sequence for unseen messages.
Definition: config.c:46
DT_BOOL
#define DT_BOOL
boolean option
Definition: types.h:30
ConfigDef
Config item definition.
Definition: set.h:61
ConfigSet
Container for lots of config items.
Definition: set.h:228
C_MaildirTrash
bool C_MaildirTrash
Config: Use the maildir 'trashed' flag, rather than deleting.
Definition: config.c:42
private.h
C_MaildirCheckCur
bool C_MaildirCheckCur
Config: Check both 'new' and 'cur' directories for new mail.
Definition: config.c:38
C_MhSeqReplied
char * C_MhSeqReplied
Config: MH sequence to tag replied messages.
Definition: config.c:45