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

Mark all read #128

Closed
sabof opened this issue Jan 8, 2013 · 13 comments
Closed

Mark all read #128

sabof opened this issue Jan 8, 2013 · 13 comments
Labels

Comments

@sabof
Copy link
Contributor

sabof commented Jan 8, 2013

Perhaps this functionality already exists, but here is a small addition.

(defun mu4e-headers-mark-all-unread-read ()
  "Put a ! \(read) mark on all visible unread messages"
  (interactive)
  (mu4e-headers-mark-for-each-if
   (cons 'read nil)
   (lambda (msg param)
     (memq 'unread (mu4e-msg-field msg :flags)))))

(defun mu4e-headers-flag-all-read ()
  "Flag all visible messages as \"read\""
  (interactive)
  (mu4e-headers-mark-all-unread-read)
  (mu4e-mark-execute-all t))
@sfischme
Copy link
Contributor

sfischme commented Mar 6, 2013

I don't have mu4e~headers-mark-for-each-if in the latest git version. It would be nice to have mu4e-flag-all-read.

@djcb
Copy link
Owner

djcb commented Apr 21, 2013

There's mu4e-headers-mark-for-each-if now (instead of mu4e~headers-mark-for-each-if, which should allow you to accomplish this. Could you redefine your function with that?

@sfischme
Copy link
Contributor

It's working with mu4e-headers-mark-for-each-if. The mu4e-flag-all-read is quite a useful feature.

@djcb
Copy link
Owner

djcb commented Apr 22, 2013

Okay, I'm adding mu4e-contrib.el for these kind of user-provided functions. @sabof: could you make a version with
mu4e-headers-mark-for-each-if, and add a docstring? Thanks.

@sabof
Copy link
Contributor Author

sabof commented Apr 22, 2013

@djcb I've updated the original post. Docstrings like what? Functions' names with dashes replaced by spaces?

@djcb
Copy link
Owner

djcb commented Apr 23, 2013

Thanks! Regarding the docstring -- it would be nice to have a little description of what the function does, in what context etc.; like all other functions :-)

@sabof
Copy link
Contributor Author

sabof commented Apr 23, 2013

I've added short comments.

@djcb
Copy link
Owner

djcb commented Apr 29, 2013

I have added this now -- thanks!

@djcb djcb closed this as completed Apr 29, 2013
@ahyatt
Copy link

ahyatt commented Feb 23, 2016

I may be a bit confused, but I don't see any evidence that it is possible to mark everything as read in mu4e. Should this be re-opened?

@gaydenko
Copy link

@ahyatt , I would select all unread headers and then:

  • select all headers: C-x h
  • mark all for deferred actions: *
  • resolve deferred actions: #
  • mark as read: !

@ahyatt
Copy link

ahyatt commented Feb 23, 2016

Thanks, I'm sure that will work, but I'd really like this to be a shorter
operation by default. In gnus, for example, you just have to press "c",
which will mark everything read and exit. It makes reading your mail very
quick. Mu4e doesn't have to be exactly like that, but hopefully can be
less than a 4-step process.

On Tue, Feb 23, 2016 at 11:33 AM Andrew Gaydenko notifications@github.com
wrote:

@ahyatt https://github.com/ahyatt , I would select all unread headers
and then:

  • select all headers: C-x h
  • mark all for deferred actions: *
  • resolve deferred actions: #
  • mark as read: !


Reply to this email directly or view it on GitHub
#128 (comment).

@djcb
Copy link
Owner

djcb commented Feb 23, 2016

There's a function mu4e-headers-mark-all-unread-read in mu4e-contrib, which you can bind to some key.

@ahyatt
Copy link

ahyatt commented Feb 24, 2016

OK, I see. Thanks, I didn't realize that the fix was checked into the contrib file. I still think it's probably worthy of inclusion into the main code, along with a useful keybinding, but that's up to you.

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

No branches or pull requests

5 participants