Age | Commit message (Collapse) | Author |
|
Don't allow the operation on a non-directory. Print a message
indicating it's not a directory.
|
|
The i variable is used in several places and scopes as a temporary
index variable, but is also used to record the current operation.
Separate them out to make the code less confusing.
|
|
Some (maybe most) IMAP mail systems allow folders to be nested inside
folders, so you can have, say, an Inbox with more folders inside it.
However, in the file browser, mutt will only open a maildir/mh
directory as a mailbox, there is no way to get to the child mailboxes.
This change adds a function <descend-directory> that forces mutt to
descend into the directory. It is unbound by default.
Signed-off-by: Corey Minyard <minyard@acm.org>
|
|
These are mostly the result of making the formatting changes commit
after the indent changes commit.
|
|
Add spaces after if, else, while, for, switch.
Unify the brace placement style. The vast majority of the code uses
Allman style so convert the relatively few K&R braces over.
|
|
These are mostly automated changes corresponding to the emacs
settings:
(c-set-style "linux")
(setq c-basic-offset 2)
(c-set-offset 'case-label '+)
Most of the code follows the convention:
(add-to-list 'c-cleanup-list 'space-before-funcall)
but this is not enforced by this indentation cleanup.
Also, I personally dislike tabs, so I have:
(setq-default indent-tabs-mode nil)
in my own configuration. However I have no desire to change every line
just for that effect. So this cleanup does nothing about the mix issue.
Some of the secondary files (e.g. regex.c) have been skipped.
I've also skipped crypt-gpgme.c, because I need to think about that
file. Werner Koch and the GnuPG team contributed most it, and it
follows the Gnu indentation settings. It should probably be made
uniform with Mutt, but I don't want to discourage future GnuPG
contribution to the file.
I manually reverted a few unsightly cleanups, and added a few tweeks
when I saw things that could be improved.
|
|
The result of
find . -name "*.[ch]" -exec emacs -batch {} \
--eval="(progn (delete-trailing-whitespace) (and (buffer-modified-p) (save-buffer)))" \;
|
|
|
|
This allows '=' and '~' mailboxes shortcuts to be turned off in the
browser mailbox list.
The default $sort_browser value of "alpha" uses strcoll(3), which
ignores some punctuation. When using multiple accounts with
dynamically changing values of $folder, this can lead to an
unintuitive sorting order. (See issue #22 for an example.)
This problem came about because of commit 8328ce68, which enabled
mutt_pretty_mailbox() calls for IMAP and POP mailboxes too. The
commit had a valid point about consistency and too-wide mailbox
listings, so I don't really want to revert it.
This option provides an alternative to completely enable/disable the
shortcuts for those who run into an issue.
|
|
The size of a directory or symlink in the folder browser is not meaningful.
For directories it means just how many blocks were allocated to hold all
entries. It does not mean that the entries are still present in the directory.
For symlinks its the size of the target.
Set both to zero to simplify the folder browser output.
Signed-off-by: Olaf Hering <olaf@aepfle.de>
|
|
|
|
Change the pager, compose, recvattach and recvcmd to pass the actx
instead of the individual idx and idxlen parameters.
Separate out the compose menu exit logic to first free the BODY data
and then call the shared actx free function at the bottom.
|
|
This removes the need for the OPTNEEDREDRAW option and MAYBE_REDRAW
macro previously used to communicate back the need to refresh after
exiting a menu.
Remove the redraw parameter from ci_bounce_message() and
mix_make_chain() which served the same purpose.
|
|
Change the pager to use a MENU, right now just to hold the refresh
state.
|
|
Mailbox list may not be properly displayed in a standard 80-column
terminal window if the $folder variable contains a long URL. In such
a case only left part of each entry name can be visible with the default
value of $folder_format. What's worse, this visible part may not be
enough to distinguish between the entries.
Thus in this case mutt_pretty_mailbox() will be just as useful as for
local mailboxes.
|
|
|
|
The buffer size of 16 was sufficient to hold the %d format, but not
for using %D. Change to use a SHORT_STRING.
Thanks to Ian Zimmerman for the original patch, and to Antonio Radici
for forwarding it on to us.
|
|
$locale was only used to set the LC_TIME locale. Unfortunately, Mutt
previously defaulted to using "C". This overrode the user's locale
setting and forced them to re-specify their locale inside their
.muttrc.
Remove $locale and instead use the locale specified by the
environment. Mutt still allows "C locale" dates by using a leading
"!" in $date_format, ${}, etc.
Another use of $locale was to customize attribution dates using hooks.
The next commit will introduce $attribution_locale, which can be used
for this instead.
Thanks to Derek Martin for the original patch!
|
|
%n will show the unread message count in the mailbox. %m will show
total message count. Except for %n with IMAP, these both require
$mail_check_stats to be set, which puts these counts inside BUFFY.
Since the imap_mboxcache is never fresher than the value in BUFFY,
remove the special imap_mailbox_state() call. Instead, just update
from the current Context for all mailboxes.
Remove the logic that overrode the %N format string to show unread
count for IMAP mailboxes. If they want to see unread count, they will
have to change the $folder_format.
Although it doesn't look possible to reuse browser_state.entry slots,
change the OP_DELETE_MAILBOX to memset(0) the deleted slot. Then, we
can change to logic in add_folder() so it doesn't need to zero-out
unset values.
|
|
Add and use new flag to indicate the folder is on local filesystem.
Add and use new gid, uid and nlink member.
Use existing ->mode member instead of stat->st_mode.
Use existing ->size member instead of stat->st_size.
Use existing ->mtime member instead of stat->st_mtime.
Remove struct stat, the used values were already duplicated in the struct.
This reduces memory usage.
|
|
Changeset 23334e967dd7 created a workaround for a namespace conflict
with Solaris and derivatives. After some discussion, the team decided
it would be best to move away from using the "M_" prefix for macros.
This patch was automatically generated by running:
perl -wpi -e 's/\bM_(\w+)\b/MUTT_$1/g' `find . -name '*.[ch]' -print`
with the exception that sys_socket.h was exempted. (That file will
be backed out subsequent to this commit.)
Thanks to Andras Salamon for supplying the perl script used to make
this change.
|
|
Continuing with the conversion to using windows for screen drawing,
mutt_FormatString() was directly using COLS for right justification
and similar formatting. Instead pass in a parameter, cols.
This change involved seeding the parameter through callback functions
too, as many of them call mutt_FormatString() back.
|
|
This patch only updates existing copyright notices in the source
files, using commit dates since the last copyright update in commits
e3af935cdb1a and f8fd60d8d3f2.
Add a notice to the COPYRIGHT file to refer to our mercurial
repository for the full commit history.
Add myself to the COPYRIGHT file and smime_keys.pl file.
|
|
Currently, the SSL and TLS certficate prompts turn on
OPTUNBUFFEREDINPUT, (to prevent macros and such from running right
through the dialog). Unfortunately, the menu dialog processing in
menu_dialog_dokey() is using mutt_ungetch() to forward non-dialog keys
on to standard menu processing. With OPTUNBUFFEREDINPUT set, those keys
never make it to the menu and are buffered until after the menu dialog.
This patch creates a new event buffer, separate from the standard
"unget" buffer, for use by macros, exec, and push events. These events
can be temporarily ignored by setting OPTIGNOREMACROEVENTS (renamed
from OPTUNBUFFEREDINPUT), while continuing to allow unget events to be
processed.
Since the "push" and "unget" functions now go to different buffers,
function names were slightly renamed, to make it less easy to
unintentionally use the wrong function at the wrong time.
|
|
|
|
system calls.
|
|
Many structs used in mutt are actually constant but are defined
without the 'const' keyword. This can slow initialization (slightly)
in some environments due to extra copying and increases the amount of
writable RAM required at run-time, which can be significant on non-MMU
systems. Using const can also increase the opportunities for compiler
optimization.
The attached patch marks many such structures as const. On my test x86
build, this reduces the size of .data by over 50%.
|
|
As requested by Rocco Rutte in bug #2421 increase the type to int.
Signed-off-by: Olaf Hering <olaf@aepfle.de>
|
|
The content of the regex_t structure is undefined in this case.
|
|
|
|
properly set the locale for LC_TIME prior to calling strftime()
closes #1734
closes #3406
|
|
|
|
|
|
Instead of using the (pointless) mtime of the top-level maildir folder,
use the latest mtime of the "new" and "cur" subdirectories. Maildir
folders in the mailboxes list can now be properly sorted by date. This
does not affect the directory browser. Also see #2421.
|
|
|
|
|
|
|
|
I went through the logs of each file with a copyright header and
updated the years for the authors in the headers for any non-comment
changes they introduced. What a pain!
|
|
Previously, the pattern was thrown away during menu destruction.
For the next search, mutt then can't provide a good suggestion.
The new behaviour is to manage the pattern outside the lifecyle
to always provide the last pattern as suggestion.
|
|
This requires to add the buffer size as parameter since the result may
be longer than the original but still fit in the buffer. Closes #2948.
|
|
dir (closes #2471).
|
|
|
|
|
|
|
|
'%c' in $hdr_format
|
|
|
|
Even on 80x25 terminals, SHORT_STRING (128 byte) may not be enough so use
LONG_STRING (1k) as STRING (256 byte) may well be too short for wider
terminals. Closes debian #4152777.
|
|
|
|
when explicitly requested. Closes: #2089.
|
|
|