From mboxrd@z Thu Jan 1 00:00:00 1970 From: Richard KLINDA Subject: New :base-extension parameter: :none Date: Thu, 12 Feb 2009 16:07:44 +0100 Message-ID: <87eiy3ae2n.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LXdD7-0005r7-B6 for emacs-orgmode@gnu.org; Thu, 12 Feb 2009 10:10:41 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LXdD5-0005qG-HJ for emacs-orgmode@gnu.org; Thu, 12 Feb 2009 10:10:40 -0500 Received: from [199.232.76.173] (port=51852 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LXdD5-0005qA-8v for emacs-orgmode@gnu.org; Thu, 12 Feb 2009 10:10:39 -0500 Received: from viefep20-int.chello.at ([62.179.121.40]:23292) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LXdD3-00080a-S6 for emacs-orgmode@gnu.org; Thu, 12 Feb 2009 10:10:39 -0500 Received: from edge02.upc.biz ([192.168.13.237]) by viefep20-int.chello.at (InterMail vM.7.09.01.00 201-2219-108-20080618) with ESMTP id <20090212151017.URJA10684.viefep20-int.chello.at@edge02.upc.biz> for ; Thu, 12 Feb 2009 16:10:17 +0100 Received: from ignotus by localhost with local (masqmail 0.2.21) id 1LXdAG-1Bn-00 for ; Thu, 12 Feb 2009 16:07:44 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Hello, I don't use filename extensions for my org files and I could not publish my files that way because you have to give a string parameter to :base-extension. I modified the org-publish-get-base-files function to support a :none keyword, that means that every file gets exported (except those thats name start with a dot): ,---- | '("test" . (:base-directory "~/test/" | :base-extension :none ;; <---- new :none keyword | :publishing-directory "/tmp/" | :with-section-numbers nil | :table-of-contents nil | )) `---- Here is the modified function, 2 lines changed (look for the "<-----"). Carsten, please include this change in the next version of Org if you think it's ok, thank you. ,---- | (defun org-publish-get-base-files (project &optional exclude-regexp) | "Return a list of all files in PROJECT. | If EXCLUDE-REGEXP is set, this will be used to filter out | matching filenames." | (let* ((project-plist (cdr project)) | (base-dir (file-name-as-directory | (plist-get project-plist :base-directory))) | (include-list (plist-get project-plist :include)) | (recurse (plist-get project-plist :recursive)) | (extension (or (plist-get project-plist :base-extension) "org")) | (match (if (eq extension :none) ;; <----- | "^[^\\.]" ;; <----- | (concat "^[^\\.].*\\.\\(" extension "\\)$")))) | (setq org-publish-temp-files nil) | (org-publish-get-base-files-1 base-dir recurse match | ;; FIXME distinguish exclude regexp | ;; for skip-file and skip-dir? | exclude-regexp exclude-regexp) | (mapc (lambda (f) | (pushnew | (expand-file-name (concat base-dir f)) | org-publish-temp-files)) | include-list) | org-publish-temp-files)) `---- -- Udv, Richard