Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Folder structure for accounts #42

Open
vitis586 opened this issue Mar 18, 2023 · 2 comments
Open

Folder structure for accounts #42

vitis586 opened this issue Mar 18, 2023 · 2 comments

Comments

@vitis586
Copy link

Hello,

I am running this in a docker container. I want to save multiple folders from single account. As imapbox does not support multiple remote folders with one account, I just duplicated the account and use different remote folder for each. Everything works, but..

The config is as follows

[imapbox]
local_folder=/var/imapbox
days=365
wkhtmltopdf=/opt/bin/wkhtmltopdf

[account1]
host=imap.example.com
username=[email protected]
password=password
remote_folder=INBOX

[account2]
host=imap.example.com
username=[email protected]
password=password
remote_folder=archive

[account3]
host=imap.example.com
username=[email protected]
password=password
remote_folder=sent

Imapbox runs and downloads all the mail, but the folder structure is following

  • home
    • INBOX
      • 2023
      • 2022
      • archive
        • 2023
        • sent
          • 2023

Imapbox runs and writes the email, but then does not go back to home and runs further in the account1 folder and that just continues. I would expect to have the remote folders as subfolders in home. I bet that it is something simple, but I am not on that level yet. :)

I am not sure how to name this issue, so you might come up with something better than I did.

@polo2ro
Copy link
Owner

polo2ro commented Mar 21, 2023

folders = str.split(account['remote_folder'], ',')

you should try with a comma, the readme is probably not up to date

@vitis586
Copy link
Author

Yes, you are correct. More remote folders are indeed supported that way. When I used remote_folder=INBOX,sent instead of multiple account, it went as expected. I would go with a separate container for multiple accounts anyway, because I would want a different local folders.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants