On 2005-10-30, at 1300, Tom Collins wrote:
On Oct 30, 2005, at 9:35 AM, Anilkumar wrote:
it create the user perfectly with his Inbox
i want to create four (4) new folder at the time of creating a new user

Edit the function make_user_dir() in vpopmail.c. At the beginning of the function, it has a list of folders to create for every user:

 const char *dirnames[] = {"Maildir", "Maildir/new", "Maildir/cur",
        "Maildir/tmp", "Maildir/Inbox", "Maildir/Inbox.Sents",
        "Maildir/Inbox.Drafts", "Maildir/Inbox.Trash",
        "Maildir/Inbox.Spam Mail"};

wouldn't you also need the ".../new", ".../cur", and ".../tmp" entries within each of the folders as well?

and what virtual folder system are you using which would create a folder called "Inbox"? courier-imap doesn't create folders like that- if you're using courier-imap the list would look something like this:

    Maildir
    Maildir/new
    Maildir/cur
    Maildir/tmp
    Maildir/.Sent
    Maildir/.Sent/new
    Maildir/.Sent/cur
    Maildir/.Sent/tmp
    Maildir/.Drafts
    Maildir/.Drafts/new
    Maildir/.Drafts/cur
    Maildir/.Drafts/tmp
    Maildir/.Trash
    Maildir/.Trash/new
    Maildir/.Trash/cur
    Maildir/.Trash/tmp
    Maildir/.Spam
    Maildir/.Spam/new
    Maildir/.Spam/cur
    Maildir/.Spam/tmp

i think the best way to find the list would be to create a dummy mailbox using the existing vpopmail, create the folder structure you want to see within that dummy mailbox, and then use something like this to see the list of directories you need to create (and therefore need to add to the "dirnames" array.)

    # cd `vuserinfo -d [EMAIL PROTECTED]
    # find . -type d

remove the "." or "./" from the beginning of each line, and that's the list you need.

--------------------------------------------------
| John M. Simpson - KG4ZOW - Programmer At Large |
| http://www.jms1.net/           <[EMAIL PROTECTED]> |
--------------------------------------------------
| Mac OS X proves that it's easier to make UNIX  |
| pretty than it is to make Windows secure.      |
--------------------------------------------------


Attachment: PGP.sig
Description: This is a digitally signed message part

Reply via email to