nmh-workers
[Top] [All Lists]

folder-specific defaults

2002-07-08 14:40:35
Gentlefolk,

I'm trying to build a solution to most objections against
folder-specific defaults in the mailfolders. You will get
two new options in your mh_profile: config-prefix and
config-postfix.

For prefix, postfix and folder I recognize three possible
values:
A- Fixed path (exactly . or .. or starting with / . .. or ~)
B- Any other value
C- Empty

I'm still considering wether undef/null would also be a value to
test on. undef/null would be hard to override in specific cases,
although I think we don't want commandline options for the pre-
and postfix, because in those cases just giving -form or -filter
options might be easier/better/simpler.

In column four I give the way in which I build the path to the
directory that should contain the config files. In column five
I indicate whether recursion (by reducing folder from right to
left) would be appropriate.

prefix  postfix folder                                  recurse
A       A       A       m_maildir(postfix)              -
A       B       A       -                               -
A       C       A       -                               -
B       A       A       m_maildir(postfix)              -
B       B       A       -                               -
B       C       A       -                               -
C       A       A       maildir(postfix)                -
C       B       A       maildir(folder)+postfix         -
C       C       A       maildir(folder)+postfix         -
A       A       B       maildir(postfix)                -
A       B       B       maildir(prefix)+folder+postfix  +
A       C       B       maildir(prefix)+folder+postfix  +
B       A       B       maildir(postfix)                -
B       B       B       maildir(prefix)+folder+postfix  +
B       C       B       maildir(prefix)+folder+postfix  +
C       A       B       maildir(postfix)                -
C       B       B       maildir(folder)+postfix         +
C       C       B       maildir(folder)+postfix         +

- maildir() is the m_maildir function that returns a dir from a
  foldername, allowing for fixed paths, etc. This does not handle
  tildes, should it? (Tildes are handled in etcpath for config, and
  I think not for folders?)
- Public folders: if you plan to use public folders, make sure to use a
  prefix, this keeps you in control of anything you access as a
  folder, and makes sure you don't use folder specific config for
  absolute paths.
- Absolute path on the postfix is a bit of an odd duck. This gives
  one fixed directory (as opposed to a tree) to put all your config.
  This is identical to the current situation, except that you can choose
  the location separately from your folders.
- Perhaps I should recognize empty/empty as not wanting folder specific
  defaults, and handle appropriately? But how do I then indicate that
  I want config in my folders. Using / or ./ for pre or postfix would
  not work. Using ~/Mail for prefix seems a bit redundant? This is where
  having a different interpretation for '' and null could be usefull.
  Alternatively, have a third flag to indicate use of : recurse, prefix
  and/or postfix.

Does anyone see a problem with this approach?

Tobias


<Prev in Thread] Current Thread [Next in Thread>
  • folder-specific defaults, Tobias Nijweide <=