org-mode/lisp
Sebastian Rose f2eec6921f Make org-publish-attachment honor directory structure
* lisp/org-publish.el (org-publish-attachment): Put the attachment
into the right directory.

Aidan Gauland <aidalgol@no8wireless.co.nz> writes:
> On Thu, Sep 16, 2010 at 12:40:34AM +0200, Sebastian Rose wrote:
>> Aidan Gauland <aidalgol@no8wireless.co.nz> writes:
>> > Sebastian Rose <sebastian_rose <at> gmx.de> writes:
>> >> It would be a bug.
>> >>
>> >> But I cannot reproduce it (current Org mode from git, emacs24).
>> >
>> > I just figured out why: I store all my images in ~/images/ and just
>> > have symbolic links to them in my Org website directory.
>> >
>> > Can you reproduce it now that you have this piece of information?
>>
>>
>> Ah, OK.  That might be because of some call to
>>
>>   (file-truename file...)
>>
>> or similar.  `file-truename' removes symbolic links in filenames.
>>
>> Functions like this are called to make sure, the file is published only
>> if needed (i.e. the file has changed since last export).
>>
>> I'm not sure currently if it's clever to remove such calls (see
>> lisp/org-publish.el and search `file-truename').
>
> What if `file-truename' was used only to get the path of the actual
> file to copy, but the (relative) path of the link is used as the
> destination?
>
> --Aidan

Hi Aidan,

`org-publish-attachment' is wrong or called with wrong arguments.

This patch fixes it.

As always, there might be a better way to fix it,
but this way the function `org-publish-attachment' will work regardless
of parameters.  Someone will always call this function with the wrong
`PUB-DIR' parameter...

Aidan, would like to apply the patch and verify it works for you?

Best wishes,

  Sebastian
2010-09-16 18:00:59 +02:00
..
ob-C.el Babel language files should not require org mode explicitly 2010-09-10 09:33:00 -06:00
ob-R.el ob-R.el: Bugfix: explicitely set variables to `nil'. 2010-09-05 17:41:23 +02:00
ob-asymptote.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-clojure.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-comint.el babel: Eliminate compiler warnings 2010-08-30 18:20:01 -07:00
ob-css.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
ob-ditaa.el ob-ditaa: now expands tildas in org-ditaa-jar-path 2010-09-01 18:08:26 -06:00
ob-dot.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-emacs-lisp.el Fix some more Org `check-declare' issues. 2010-08-27 14:45:48 -06:00
ob-eval.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
ob-exp.el now possible to abort code block evaluation without throwing errors 2010-08-26 17:14:43 -06:00
ob-gnuplot.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-haskell.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-js.el ob-js: now supports session based evaluation through mozrepl 2010-09-01 08:48:21 -06:00
ob-keys.el a new function for jumping to the head of the current code block 2010-09-08 00:13:12 -06:00
ob-latex.el Babel: fixing compiler warnings 2010-08-27 14:45:55 -06:00
ob-ledger.el Babel language files should not require org mode explicitly 2010-09-10 09:33:00 -06:00
ob-lisp.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-lob.el babel: edit docstring 2010-08-19 09:31:19 -04:00
ob-matlab.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
ob-mscgen.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
ob-ocaml.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
ob-octave.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-org.el ob-org: no longer drop first line when exporting org code block 2010-09-09 00:38:14 -06:00
ob-perl.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-plantuml.el ob-plantuml: raises an error when the :file header argument is not set 2010-09-07 23:23:08 -06:00
ob-python.el babel: python: refactor `org-babel-python-evaluate' 2010-09-07 21:58:58 -04:00
ob-ref.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
ob-ruby.el ob-ruby: only require inf-ruby when absolutely necessary 2010-09-02 09:03:08 -06:00
ob-sass.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-scheme.el ob-scheme: now supports session-based evaluation 2010-08-31 01:14:02 -06:00
ob-screen.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
ob-sh.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-sql.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-sqlite.el Babel now cleans up any temporary files created using org-babel-temp-file 2010-08-25 14:47:47 -06:00
ob-table.el ob-table: babel scripts called from tables can accept ranges 2010-07-21 16:11:49 -07:00
ob-tangle.el autoload org-babel-tangle-lang-exts from ob-tangle 2010-09-08 11:33:24 -06:00
ob.el removing org-babel-temp-directory until some issues are resolved 2010-09-13 11:55:38 -04:00
org-agenda.el Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode 2010-09-16 17:20:02 +02:00
org-archive.el Use global archive location default 2010-09-11 07:38:27 +02:00
org-ascii.el Bind and set link path for link type specific markup function 2010-09-07 20:04:35 +02:00
org-attach.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-bbdb.el org-bbdb: Ignore case in anniv class string. 2010-08-12 11:03:07 +02:00
org-beamer.el Revert "Search for LaTeX setup case-insensitively" 2010-08-20 18:24:09 +02:00
org-bibtex.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-capture.el Small fix in doc string 2010-09-12 18:45:04 +02:00
org-clock.el Properly declare function to silence byte compiler 2010-09-07 20:03:30 +02:00
org-colview-xemacs.el Allow "#" and "%" in tags 2010-08-31 08:25:20 +02:00
org-colview.el Allow "#" and "%" in tags 2010-08-31 08:25:20 +02:00
org-compat.el Do not use looking-at-p when it does not exist 2010-08-17 06:32:55 +02:00
org-crypt.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-ctags.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-datetree.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-docbook.el Do not crash when trying to export an ill-formed list in HTML and DocBook. 2010-09-01 19:05:56 +02:00
org-docview.el Remove compile-time dependency on doc-view.el 2010-08-29 21:29:16 +02:00
org-entities.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-exp-blocks.el org-exp-blocks now expands blocks *after* including files 2010-09-07 23:50:27 -06:00
org-exp.el Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode 2010-09-16 17:20:02 +02:00
org-faces.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-feed.el Fix typo in customization group :tag property 2010-09-15 11:36:17 +02:00
org-footnote.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-freemind.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-gnus.el Declare function to silence byte compiler 2010-09-09 14:51:16 +02:00
org-habit.el org-habit.el: better error handling required 2010-08-25 12:16:47 +02:00
org-html.el org-html.el: Fix exporting link to .org files. 2010-09-12 19:54:50 +02:00
org-icalendar.el Allow iCalendar to use UTC for exported date-time. 2010-09-14 14:05:31 +02:00
org-id.el Autoload org-id-store-link 2010-07-21 18:37:34 +02:00
org-indent.el Fix org-indent-mode message when mode is refused 2010-08-09 21:52:33 +02:00
org-info.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-inlinetask.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-irc.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-jsinfo.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-latex.el LaTeX export: Configurable format for tags 2010-09-14 14:42:37 +02:00
org-list.el Small refactoring and docstrings update 2010-09-15 11:07:42 +02:00
org-mac-message.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-macs.el moved `org-save-outline-visibility' into org-macs.el 2010-08-27 08:18:32 -06:00
org-mew.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-mhe.el Remove possible folding white space in message header field 2010-09-15 18:59:22 +02:00
org-mks.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-mobile.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-mouse.el Replace non-interactive use of `org-next-item' and `org-previous-item'. 2010-09-12 18:53:18 +02:00
org-plot.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-protocol.el org-protocol default template should be nil 2010-09-02 16:41:53 +02:00
org-publish.el Make org-publish-attachment honor directory structure 2010-09-16 18:00:59 +02:00
org-remember.el Allow "#" and "%" in tags 2010-08-31 08:25:20 +02:00
org-rmail.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-src.el Explicitly mention when a language-mode throws an error 2010-09-14 14:03:15 +02:00
org-table.el Align table before converting it to a table.el table 2010-08-18 08:35:15 +02:00
org-taskjuggler.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-timer.el Require org-clock.el where needed. 2010-09-07 02:28:06 +02:00
org-vm.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-w3m.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org-wl.el Don't try to store link if point is at end of buffer. 2010-08-23 19:35:43 +02:00
org-xoxo.el Mention release 7.01 on the website, push release number to 7.01trans 2010-07-19 08:33:24 +02:00
org.el Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode 2010-09-16 17:20:02 +02:00