emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nick Dokos <nicholas.dokos@hp.com>
To: dericbytes <dericbytes@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: headline entries order.
Date: Tue, 14 Apr 2009 18:09:04 -0400	[thread overview]
Message-ID: <18142.1239746944@gamaville.dokosmarshall.org> (raw)
In-Reply-To: Message from dericbytes <dericbytes@gmail.com> of "Tue, 14 Apr 2009 20:24:58 -0000." <loom.20090414T202133-656@post.gmane.org>

dericbytes <dericbytes@gmail.com> wrote:

> I want to reverse the entries of my logs. So the newest is at the top. I know
> there is the C-c ^ sort function, but I'm not sure if any are applicable. (Not
> all of my entries are dated)
> 

o If you are trying to rearrange headings and there is no "natural"
order, then the best I can offer is to number them by hand, use org-sort
and then strip the numbers out again. For simple cases (e.g. to reverse
the order of the entries), the numbering can be done by a program, but
you will have to write that program (I'd use an awk script.) Or you can
add dates to the entries that are missing them (interpolating between
the closest entries that *are* date-marked) - and you won't even have to
strip them out again.

o If what you are trying to do is enter your entries with org-remember and
you want to set up the template so that the new ones go at the top, this
portion of the Org manual should help:


,----
| 9.1.2 Remember templates
| ------------------------
| 
| In combination with Org, you can use templates to generate different
| types of remember notes.  For example, if you would like to use one
| template to create general TODO entries, another one for journal
| entries, and a third one for collecting random ideas, you could use:
| 
|      (setq org-remember-templates
|       '(("Todo" ?t "* TODO %?\n  %i\n  %a" "~/org/TODO.org" "Tasks")
|         ("Journal" ?j "* %U %?\n\n  %i\n  %a" "~/org/JOURNAL.org")
|         ("Idea" ?i "* %^{Title}\n  %i\n  %a" "~/org/JOURNAL.org" "New Ideas")))
| 
| In these entries, the first string is just a name, and the character
| specifies how to select the template.  It is useful if the character is
| also the first letter of the name.  The next string specifies the
| template.  Two more (optional) strings give the file in which, and the
| headline under which the new note should be stored.  The file (if not
| present or `nil') defaults to `org-default-notes-file', the heading to
| `org-remember-default-headline'.  If the file name is not an absolute
| path, it will be interpreted relative to `org-directory'.  The heading
| can also be the symbols `top' or `bottom' to send note as level 1
| entries to the beginning or end of the file, respectively.
`----

HTH,
Nick

  reply	other threads:[~2009-04-14 22:10 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-14 20:24 headline entries order dericbytes
2009-04-14 22:09 ` Nick Dokos [this message]
2009-04-14 23:17   ` Bernt Hansen
2009-04-18 15:38 ` I wrote code to reverse top-level entries order within region dericbytes
2009-04-19  1:15   ` Nick Dokos
2009-04-19 11:45     ` thanks nick dericbytes

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=18142.1239746944@gamaville.dokosmarshall.org \
    --to=nicholas.dokos@hp.com \
    --cc=dericbytes@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).