From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bob Newell Subject: Re: org-drill vocabulary and question about properties Date: Wed, 31 Jul 2019 17:09:37 -1000 Message-ID: <871ry5inta.fsf@bobnewell.net> References: <87r266xanj.fsf@zamazal.org> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:53787) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1ht1TM-0006YX-6J for emacs-orgmode@gnu.org; Wed, 31 Jul 2019 23:09:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ht1TL-00007Y-6i for emacs-orgmode@gnu.org; Wed, 31 Jul 2019 23:09:44 -0400 Received: from mail-pl1-x629.google.com ([2607:f8b0:4864:20::629]:43654) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ht1TK-00006B-PE for emacs-orgmode@gnu.org; Wed, 31 Jul 2019 23:09:43 -0400 Received: by mail-pl1-x629.google.com with SMTP id 4so24450651pld.10 for ; Wed, 31 Jul 2019 20:09:41 -0700 (PDT) Received: from localhost (udp072992uds.hawaiiantel.net. [141.239.244.209]) by smtp.gmail.com with ESMTPSA id v138sm79967314pfc.15.2019.07.31.20.09.38 for (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Wed, 31 Jul 2019 20:09:39 -0700 (PDT) In-Reply-To: <87r266xanj.fsf@zamazal.org> (Milan Zamazal's message of "Wed, 31 Jul 2019 21:32:32 +0200") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: emacs-orgmode@gnu.org Milan Zamazal writes: > GB> still only once there. If I want to track the learning in both > GB> directions separately, I need to make two items for one word, > GB> once german-spanish and once spanish-german. Am I right? I've used org-drill for both English/Hawaiian and English/Hindi, and I've never been able to get balanced two-way drills without making separate cards for each direction. But making card pairs is really easy to automate. I make a .org file with words in one direction only, semicolon separated like this: hindiword1;englishword1 hindiword2;englishword2 etc. etc. and then call the following elisp. (Obviously works for any pair of languages.) The elisp sets up a two-way org drill file that does what I want. The coding is crude and could be improved however it works, which is something of a benefit :) ;; Make Hindi flashcards for org-drill ;; Pseudo-Two sided, English/Hindi (defun org-make-hindi () "Make Hindi flashcards" (interactive) (goto-char (point-min)) ;; Process each line top to bottom. (while (not (eobp)) (beginning-of-line) (setq frontofline (point)) (search-forward ";") (backward-delete-char 1) (setq partone (buffer-substring frontofline (point))) (delete-region frontofline (point)) (setq frontofline (point)) (end-of-line) (setq parttwo (buffer-substring frontofline (point))) (delete-region frontofline (point)) (delete-char 1) (insert (concat "** Word :drill:\n:PROPERTIES:\n:END:\n" partone "\n*** A\n" parttwo "\n" "** Word :drill:\n:PROPERTIES:\n:END:\n" parttwo "\n" "*** A\n" partone "\n")) ) ) -- Bob Newell Honolulu, Hawai`i * Via Gnus/BBDB/Org/Emacs/Linux *