all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Nick Dokos <nicholas.dokos@hp.com>
To: "Thomas S. Dye" <tsd@tsdye.com>
Cc: Bernt Hansen <bernt@norang.ca>,
	nicholas.dokos@hp.com, kmartino@pobox.com, emacs-orgmode@gnu.org,
	Carsten Dominik <carsten.dominik@gmail.com>
Subject: Re: Re: One org file, multiple exports, is it possible?
Date: Wed, 26 May 2010 21:40:40 -0400	[thread overview]
Message-ID: <10751.1274924440@gamaville.dokosmarshall.org> (raw)
In-Reply-To: Message from "Thomas S. Dye" <tsd@tsdye.com> of "Wed, 26 May 2010 12:28:12 -1000." <2FF8A80C-C4F3-4FDE-B0D2-50D03EE4110B@tsdye.com>

Thomas S. Dye <tsd@tsdye.com> wrote:

> On May 26, 2010, at 11:37 AM, Nick Dokos wrote:
>     ...
>     perhaps? But I'm shooting from the hip here, so take it with the appropriate
>     grain of salt.
>    
> 
> Hi Nick,
> 
> The documentation for org-publish-projects-alist suggests that :include wants a list:
> 
>     The :include property may be used to include extra files.  Its
>     value may be a list of filenames to include. The filenames are
>     considered relative to the base directory.
> 
> When I tried :include "index.org" I got this:
> 
> Debugger entered--Lisp error: (wrong-type-argument sequencep 105)
>   concat("~/org/temp/" 105)
>   (expand-file-name (concat base-dir f)) 
>   ...
> 

Yep, shot from the hip and hit my foot. You are right.

> I'm not going to pretend I know what I'm talking about here, but AFAICT the variable i in the following code needs some attention before it goes to
> string-match.  According to the documentation, plist-get just returns the value assigned to a property (or nil) without doing anything to it, so i
> should be a list when it is passed to string-match.  string-match wants REGEXP here, apparently not as a list.  I couldn't persuade emacs to cough up
> the definition of REGEXP, but my brief forays into the emacs and org-mode source code lead me to believe it is probably a string.
> 
>     (defun org-publish-get-project-from-filename (filename &optional up)
>       "Return the project FILENAME belongs."
>       (let* ((filename (expand-file-name filename))
>     project-name)
>    
>         (catch 'p-found
>           (dolist (prj org-publish-project-alist)
>     (unless (plist-get (cdr prj) :components)
>      ;; [[info:org:Selecting%20files]] shows how this is supposed to work:
>      (let* ((r (plist-get (cdr prj) :recursive))
>     (b (expand-file-name (plist-get (cdr prj) :base-directory)))
>     (x (plist-get (cdr prj) :base-extension))
>     (e (plist-get (cdr prj) :exclude))
>     (i (plist-get (cdr prj) :include))
>     (xm (concat "^" b (if r ".+" "[^/]+") "\\.\\(" x "\\)$")))
>        (when (or
>       (and i (string-match i filename))
> 

I think you are right that there is a problem here. Here is an excerpt
from the relevant commit:

,----
| commit 339d6fe4bbf7b9858c6323d01f32d0c73a4cd3a8
| Author: Sebastian Rose <sebastian_rose@gmx.de>
| Date:   Thu May 13 13:43:53 2010 +0200
| 
|     Publishing, cashing and timestamps
|     
|     Carsten Dominik <carsten.dominik@gmail.com> writes:
|     > Hi Sebastian,
|     >
|     > sorry for being slow.  Could you do me a favor and send me the cache patch one
|     > more time - if possible updated to the current master.
|     >
|     > I am just not sure I have the right patch in my hands.
|     
|     Hi Carsten,
|     
|     no problem. The patch is attached.
|     
|     Here is a list of my ChangeLog entries, redated to today:
|     
|     2010-05-13  Sebastian Rose  <sebastian_rose@gmx.de>
|     
|         ...
|     
|     	* org-publish.el (org-publish-get-project-from-filename) does
|     	not depend on a list of files anymore. Instead of laoding all
|     	files of all, we walk `org-publish-project-alist' until we
|     	find a project, where the properties :base-directory, :recursive,
|     	:base-extension, :include and :exclude match.
|     
|         ...
`----

Maybe Sebastian (I added him to the CC:) can take a look? 

Thanks,
Nick

      reply	other threads:[~2010-05-27  1:40 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-22 23:46 One org file, multiple exports, is it possible? Karl Martino
2010-05-23  0:47 ` Karl Martino
2010-05-23  4:59 ` Carsten Dominik
2010-05-23 12:22   ` Karl Martino
2010-05-23 15:58     ` Eric Schulte
2010-05-23 16:17     ` Carsten Dominik
2010-05-23 16:31       ` Karl Martino
2010-05-23 18:49         ` Thomas S. Dye
2010-05-23 20:57           ` Carsten Dominik
2010-05-23 22:01             ` Thomas S. Dye
2010-05-24  5:20               ` Carsten Dominik
2010-05-24 16:36                 ` Thomas S. Dye
2010-05-25  3:38                 ` Thomas S. Dye
2010-05-25  3:50                   ` Bernt Hansen
2010-05-25 16:20                     ` Thomas S. Dye
2010-05-25 16:52                       ` Nick Dokos
2010-05-25 17:51                         ` Thomas S. Dye
2010-05-28  3:40                         ` Thomas S. Dye
2010-05-25 17:26                       ` Mark Elston
2010-05-25 17:53                         ` Thomas S. Dye
2010-05-26 18:42                     ` Thomas S. Dye
2010-05-26 21:37                       ` Nick Dokos
2010-05-26 22:28                         ` Thomas S. Dye
2010-05-27  1:40                           ` Nick Dokos [this message]

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

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

  git send-email \
    --in-reply-to=10751.1274924440@gamaville.dokosmarshall.org \
    --to=nicholas.dokos@hp.com \
    --cc=bernt@norang.ca \
    --cc=carsten.dominik@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=kmartino@pobox.com \
    --cc=tsd@tsdye.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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.