From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: STill errorneous Treestyle sitemap Date: Sun, 2 Nov 2008 08:08:09 +0100 Message-ID: References: <490B68E9.5060302@gmx.de> Mime-Version: 1.0 (Apple Message framework v929.2) Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KwX4M-0002fp-7V for emacs-orgmode@gnu.org; Sun, 02 Nov 2008 02:08:18 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KwX4K-0002fb-LR for emacs-orgmode@gnu.org; Sun, 02 Nov 2008 02:08:17 -0500 Received: from [199.232.76.173] (port=54398 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KwX4K-0002fY-ID for emacs-orgmode@gnu.org; Sun, 02 Nov 2008 02:08:16 -0500 Received: from ug-out-1314.google.com ([66.249.92.171]:29798) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KwX4J-0007BV-Tv for emacs-orgmode@gnu.org; Sun, 02 Nov 2008 02:08:16 -0500 Received: by ug-out-1314.google.com with SMTP id 36so1779265uga.17 for ; Sun, 02 Nov 2008 00:08:14 -0700 (PDT) In-Reply-To: <490B68E9.5060302@gmx.de> 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: sebastian_rose@gmx.de Cc: "[emacs-orgmode]" Hi Sebastian, Fix A seems good to me, I have added it, many thanks. - Carsten On Oct 31, 2008, at 9:22 PM, Sebastian Rose wrote: > Hi, > > > mea culpa: The treestyle sitemap is still wrong. > > This tree > > pub > | > +--A > | | > | +-- B > | | | > | | +-- file1 > | | > | +-- C > | | > | +-- file2 > > > _looks_ great in the sitemap, but _is_ wrong. The link to > C looks like this: > > C > > instead of > > C > > > > Two different ways to fix this: > > > A) Don't link to directories anymore. > > I think this is quite a good solution, since in production > evironments those links will not work, if no index.html exists > in the directory. If it exists, it will be in the index file > anyway. > > diff --git a/lisp/org-publish.el b/lisp/org-publish.el > index e0cf4bd..d2b4c1f 100644 > --- a/lisp/org-publish.el > +++ b/lisp/org-publish.el > @@ -656,9 +656,8 @@ Default for INDEX-FILENAME is 'index.org'." > (pop subdirs)) > (dolist (d subdirs) > (setq subdir (concat subdir d "/")) > - (insert (concat indent-str " + [[file:" > - subdir "][" d "/]]\n")) > - (setq indent-str (make-string > + (insert (concat indent-str " + " d "\n")) > + (setq indent-str (make-string > (+ (length indent-str) 2) ?\ ))))))) > ;; This is common to 'flat and 'tree > (insert (concat indent-str " + [[file:" link "][" > > > > > B) Fix it, so that the link is correct (no patch yet :-( ). > > > > > What do you think? > > > > Sebastian > > > > > _______________________________________________ > 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