6

You can use a regular expression in a tags search. A tag search for {.*} will match any tag and conversely, -{.*} will no tag.


5

org-agenda supports many bulk actions. Do an org-agenda search (C-c a) that matches the entries you're interested in. In the agenda view use m to mark them (or * to mark everything) and the B to select a bulk action. The + action will add a tag to each entry.


4

Here is one approach to hide tags in folded view, and show them in any expanded view. (defun org-toggle-tag-visibility (state) "Run in `org-cycle-hook'." (message "%s" state) (cond ;; global cycling ((memq state '(overview contents showall)) (org-map-entries (lambda () (let ((tagstring (nth 5 (org-heading-components))) ...


3

As org files are plain text files, we can add tags using a simple approach: query-replace-regexp. Go to the beginning of the buffer. Do M-x query-replace-regexp or use the default binding C-M-%. Enter regexp to match the org headings: ^\*+\s-+.* To add a tag, you basically append the heading with a space, a : and the tag. So the replacement text would be \&...


2

As Yasushi Shoji mentioned, the correct approach is to let-bind org-agenda-tag-filter-preset. To advise just the one pre-built agenda view, you'll want to use advice around the function org-agenda-list, which builds just that particular view. Try this: (defun my/org-agenda-list-exclude-tags-advice (orig-fn &rest args) "Exclude selected tags from `...


2

I you don't want to see :foo:, this should exclude it: (setq org-agenda-tag-filter-preset '("-foo")) However, the doc string says: This variable should not be set directly, but agenda custom commands can bind it in the options section. So, let bind the variable before calling org-agenda by defining your own wrapper function: (defun yashi/org-agenda (...


2

Try (setq org-complete-tags-always-offer-all-agenda-tags t) I don't think you can easily add to this list from non-agenda files.


2

I use the following chunk of elisp to create a dynamic block containing a table where each row is a tag and number of use of that tag in the file. Add the block to your org file and hit C-c C-c to expand it: #+BEGIN: tagblock #+END: If you only want to count certain tags you can add a :tags option to the block and to add a label to the resulting table use ...


2

You can write a function that check if an entry has "tag1" and if so change it to "tag11": (defun change-tag (old new) (when (member old (org-get-tags)) (org-toggle-tag new 'on) (org-toggle-tag old 'off) )) Now all you have to do is apply that function to each entry that has "tag1". You can do this with org-map-entries: (defun org-rename-...


2

Have a look at Rainer Königs video on Youtube. He described the solution of your problem in excess. Rainers solution: using org mode version >=8.3, since tag hierarchies were introduced with org 8.3.


2

org-mode does not support placing inline tags within the heading, except those that appear at the very end of the heading. I suggest opening up an org-mode buffer and familiarizing oneself with the variable org-complex-heading-regexp to get a feel for how it is that org-mode knows what to do with a heading, and see that tags need to be in a special location ...


2

The function org-get-tags-at is a means by which to obtain a list of tags that can include or exclude those that are inherited based upon the second optional argument LOCAL. For a description of this particular function, see the doc-string: C-h f or M-x describe-function.


2

Refer to the Org manual section on Settings tags. It sounds like you have multiple org files, so you can specify a set of tags per file using the #+TAGS: option line. If you want a defined set of tags in all files except your journal, you can use org-tag-alist but put an empty TAGS option in the journal file. Then you can use dynamic tags and %^g in that ...


2

org-tags-view shows matches in all agenda files: you have to add this file to your agenda files (at least temporarily). You can do that with C-c[: that adds it to the front of the agenda files. You can later delete it from the list if you want with C-c] (this will delete the file at the front of the list, so I'm assuming you have not added any other files in ...


2

Dunno anything about org-agenda-cmp-user-defined etc. But if the question is just about comparing two equal-length lists of strings, in order, until the first difference is found, and returning -1 if the string from the first list is less than that of the second list, returning 1 if the reverse is true, and returning nil if there is no difference, then this ...


1

Rather than adding multiple related tag strings into your files which can be cumbersome and messy, you can define hierarchical tags that does the same thing. You can then search for the higher level tag using agenda commands and see all headers using either the higher level tag or any of the lower level tags. For example, here is a simple hierarchy EMACS > ...


1

I read through the org documentation and found that the user had to keep cursor on the #+TAGS: line and press C-c C-c in order to update the local setup. Quote from the org manual Don't forget to press C-c C-c with the cursor in one of these lines to activate any changes. After pressing C-c C-c - org mode will give a message like Local setup has ...


1

The following concept draft idea will comb through the org-agenda-files and gather all the tags that fall within ambit of regexp group 5 to org-complex-heading-regexp, and then search through that list to find out how many matches of a particular tag. The original poster may wish to perform a similar test when assigning a particular tag. USAGE: (stop-or-...


1

I use this to generate a table of clickable links: #+NAME: all-tags #+BEGIN_SRC emacs-lisp (let ((new (list))) (dolist (tag (org-global-tags-completion-table)) (setq tag (car tag)) (push (concat "[[tag:" tag "][" tag "]]\n") new)) (sort new 'string<)) #+END_SRC #+RESULTS: all-tags | [[tag:3d][3d]] | | [[tag:Android][Android]] | | [[tag:...


1

If the headlines you want to change tags for are all located in a contiguous region you can highlight them all, and then use the org-change-tag-in-region command.


1

You can do a regexp search on headlines not ending in a colon: C-c a m will prompt for a match query. Type -{:$} to match headlines not ending in colon. The regular expression goes inside the curly brackets, and the minus sign is for negating the match. Note that this method ignores tag inheritance.


1

If using Org Mode See answers to this question If not using Org Mode Look at Deft package for Emacs. It isn't exactly oriented to tagging approach, rather fulltext search, and it is recursive, i.e. contents of subfolders are included too Also You may also try contacting author to provide missing functionality Generally This feature requires regex-...


1

After your comment below, I did some experimentation. I am guessing, after you move all the tags to the TAGS property, you are expecting to continue to use the normal tag related interfaces to continue working. This does not look possible. The tags are provided as properties in the property API, but that does not mean they are like real properties. They ...


Only top voted, non community-wiki answers of a minimum length are eligible