emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Erik Hetzner <egh@e6h.org>
To: Xebar Saram <zeltakc@gmail.com>
Cc: org mode <emacs-orgmode@gnu.org>
Subject: Re: org-cook
Date: Sat, 15 Mar 2014 10:38:04 -0700	[thread overview]
Message-ID: <87mwgr4b2b.wl%egh@e6h.org> (raw)
In-Reply-To: <CAOQHXPrL=8q8OzPDwtzx4ToGwErBk3LaNP7PCt5Kn1Mzma5vbg@mail.gmail.com>

At Sat, 15 Mar 2014 09:24:23 +0200,
Xebar Saram wrote:
> 
> Dear Eric and org users
> 
> i am a new(ish) org user and an avid cooker. i have started using
> orgmodeas my recipe notebook and stumbled upon the old org-cook
> thread.
> Is there so documentation on this? do you still use it?
> are there any other ideas/suggestions on using orgmode as a recipe notebook?
> what i would mainly love is a way to "scrape" recipes off websites into org

Hi Xebar,

I still use org to manage my recipes, but I don’t use the org-cook
features. It was kind of a proof of concept, and I think it could
prove useful, but it turns out I don’t often need to convert between
units.

I have been trying out the format described in [1]. I used to use a
format like:

  Grate zest from 3 of them. Combine. Add:
  - 2 tbsp peanut oil
  - 2 chicken bouillon cubes, crumbled
  - 5 onions, thinly julienned
  - salt and pepper

But the new one looks like:

  Grate zest from 3 of them. Combine. Add:
  | 2 tbsp  | peanut oil       |                  |
  | 2 cubes | chicken bouillon | crumbled         |
  | 5       | onions,          | thinly julienned |
  |         | salt and pepper  |                  |
  
I think the table structure should make it easier to manipulate,
change units, or create shopping lists. (But I create shopping lists
by hand.)

One hack I do use is the following function:

(defun org-random-element ()
  "Choose a random element from the buffer."
  (interactive)
  (let ((element-start -1)
        (count 1))
    (while (not (org-first-sibling-p))
      (org-goto-sibling t))
    (save-excursion
      (while (org-goto-sibling)
              (setq count (+ 1 count))))
    (org-forward-heading-same-level (random count))))

This chooses a random element from a list of headings. I use this to
plan meals. I just keep running the function until I see something
that I feel like cooking.

Hope that helps!

best, Erik

1. http://sachachua.com/blog/2012/06/emacs-org-grocery-lists-batch-cooking/

-- 
Sent from my free software system <http://fsf.org/>.

  reply	other threads:[~2014-03-15 17:38 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-15  7:24 org-cook Xebar Saram
2014-03-15 17:38 ` Erik Hetzner [this message]
2014-03-15 18:03   ` org-cook Xebar Saram
2014-03-15 18:18     ` org-cook Erik Hetzner
2014-03-16  0:40       ` org-cook Robert Horn
2014-03-17 14:22         ` org-cook Fletcher Charest
2014-03-17 14:26           ` org-cook Xebar Saram
2014-03-17 14:30             ` org-cook Fletcher Charest
2014-03-17 14:34             ` org-cook Ken Mankoff
2014-03-17 14:52               ` org-cook Erik Hetzner
2014-03-15 18:25     ` org-cook Alan Tyree

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=87mwgr4b2b.wl%egh@e6h.org \
    --to=egh@e6h.org \
    --cc=emacs-orgmode@gnu.org \
    --cc=zeltakc@gmail.com \
    /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).