On Dec 17, 2009, at 5:53 AM, Mueen Nawaz wrote:
On 12/16/09 03:37, Carsten Dominik wrote:This is what skip conditions are for. Here is an entry for org-agenda-custom-commands which does this for the specific "Jack" example: ("X" "Tags match ignoring done stuff" tags "Jack" ((org-agenda-skip-function '(and (org-entry-is-done-p) (outline-next-heading) (point)))))Almost. It worked if I exclude (outline-next-heading). Was there a reason you had that?
Yes, so that the search only continues after that entry. But yes, you are right, this can fail for the final entry in a file. Try '(when (org-entry-is-done) (outline-next-heading) (point))
Also, I'm pretty weak with Emacs Lisp. What does (point) do? Google's no help (obviously).
Point returns the buffer position of he cursor, in this case the position where the next entry starts.
HTH - Carsten _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. [email protected] http://lists.gnu.org/mailman/listinfo/emacs-orgmode
