From: Carsten Dominik <dominik@science.uva.nl>
To: sebastian_rose@gmx.de
Cc: "[emacs-orgmode]" <emacs-orgmode@gnu.org>
Subject: Re: Patch: correction for tree-style sitemap (org-publish)
Date: Sun, 26 Oct 2008 07:05:12 +0100 [thread overview]
Message-ID: <862634C8-1182-4FFF-85ED-8DE9A67D904C@uva.nl> (raw)
In-Reply-To: <4903B622.6030206@gmx.de>
Applied, thanks.
- Carsten
On Oct 26, 2008, at 2:13 AM, Sebastian Rose wrote:
> Issue
> =====
>
> Sitemap not correct, when mutlitple subdirectories (my fault I
> believe, sorry). Only the tree-style sitemap is affected.
>
>
> How to reproduce
> ================
>
> Try to export the following structure to HTML (directories
> marked by `/'):
>
> base-directory/
> |
> +-- B/
> | |
> | +---C/
> | | |
> | | +--- c.org
> | |
> | +---D/
> | |
> | +--- d.org
> |
> +-- E/
>
> The resulting sitemap:
>
>
> - B
> - C
> - c.org
> - B <= B again!
> -D
> - d.org
> - E
>
> Should be:
>
> - B
> -C
> - c.org
> -D
> - d.org
> - E
>
>
>
> How to fix
> ==========
>
>
> The following patch fixes it. The patch is against
> commit 523cf1fe31dc5fc0e73a973b3e1a3bde74e0263d
> Author: Carsten Dominik <carsten.dominik@gmail.com>
> Date: Sat Oct 25 12:56:42 2008 +0200
>
> Release 6.10c.
>
>
>
> diff --git a/lisp/org-publish.el b/lisp/org-publish.el
> index 2af71d3..3859442 100644
> --- a/lisp/org-publish.el
> +++ b/lisp/org-publish.el
> @@ -645,8 +645,12 @@ Default for INDEX-FILENAME is 'index.org'."
> (directory-file-name
> (file-name-directory
> (file-relative-name localdir dir))) "/"))
> - (subdir ""))
> + (subdir "")
> + (old-subdirs (split-string (file-relative-name oldlocal
> dir) "/")))
> (setq indent-str (make-string 2 ?\ ))
> + (while (string= (car old-subdirs) (car subdirs))
> + (setq indent-str (concat indent-str (make-string 2 ?
> \ )))
> + (pop old-subdirs)(pop subdirs))
> (dolist (d subdirs)
> (setq subdir (concat subdir d "/"))
> (insert (concat indent-str " + [[file:"
>
>
> _______________________________________________
> Emacs-orgmode mailing list
> Remember: use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
prev parent reply other threads:[~2008-10-26 6:05 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-26 0:13 Patch: correction for tree-style sitemap (org-publish) Sebastian Rose
2008-10-26 6:05 ` Carsten Dominik [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
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=862634C8-1182-4FFF-85ED-8DE9A67D904C@uva.nl \
--to=dominik@science.uva.nl \
--cc=emacs-orgmode@gnu.org \
--cc=sebastian_rose@gmx.de \
/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).