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

mailcheck: MailCheckCommand must use fully qualified name to fdm configuration file #1

Open
xmailla opened this issue Dec 29, 2024 · 3 comments

Comments

@xmailla
Copy link

xmailla commented Dec 29, 2024

If I put:

MailCheckCommand: fdm -f $MBLAZE/fdmrc -q fetch

running mailcheck bails out an error:

$MBLAZE/fdmrc: No such file or directory

Here is my full $MBLAZE/profile

Local-Mailbox: "Xavier Maillard" <[email protected]>
FQDN: lamaison.localdomain
Outbox: /Users/x/mail/Postés
Sendmail: /opt/pkg/bin/msmtp --file=/Users/x/.config/mail/msmtprc
Scan-Format: "%c%u%r %-3n    %10d     %17f %t %2i%s"
MailCheckCommand: fdm -f /Users/x/.config/mail/fdmrc -q fetch
MailCheckLockFile: /Users/x/.local/state/fdm.lock
MailCheckSleep: 300
MaildirBase: /Users/x/mail
InboxName: Reception

Found a workaround by entering the full path directly though.

@xmailla
Copy link
Author

xmailla commented Dec 29, 2024

Just to be complete, from my shell:

❯ ls -l $MBLAZE/fdmrc
-rw-------@ 1 x  staff   3.1K Dec 29 17:09 /Users/x/.config/mail/fdmrc

~

xmailla added a commit to xmailla/mblaze-tools that referenced this issue Dec 29, 2024
See issue haqistan#1 on original project.

My $MBLAZE is set to /Users/x/.config/mail

In my mblaze profile, I customized MailCheckCommand to be:
MailCheckCommand: fdm -f $MBLAZE/fdmrc -q fetch

My small fix permits this otherwise, mailcheck aborts.
@xmailla
Copy link
Author

xmailla commented Dec 29, 2024

That's not the perfect solution but it is a good starting point.

xmailla added a commit to xmailla/mblaze-tools that referenced this issue Dec 30, 2024
See issue haqistan#1 on original project.

My $MBLAZE is set to /Users/x/.config/mail

In my mblaze profile, I customized MailCheckCommand to be:
MailCheckCommand: fdm -f $MBLAZE/fdmrc -q fetch

My small fix permits this otherwise, mailcheck aborts.
@xmailla
Copy link
Author

xmailla commented Dec 30, 2024

I amended my commit so that any variable could be introduced in the MailCheckCmd profile option. Tested and approved here.

xmailla added a commit to xmailla/mblaze-tools that referenced this issue Jan 4, 2025
Fixes issue haqistan#1 by adding a new function to query option in the user
profile.

Thi version is both more robust and reliable when a user uses variables
(like $HOME, $BLAZE or anything else) in his profile to specify path to
commands or files.

With this patch, user can now have this:
MailCheckIndexCommand: mairix -f $MBLAZE/mairixrc

It will be automatically transformed as: mairix -f
/whatever/path/to/file/mairixrc at runtime.

All the options are now using getmblazeopt to be filled.

This commit is replacing 517694b
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

1 participant