* org-publish not publishing changed files @ 2011-03-19 1:16 Aidan Gauland 0 siblings, 0 replies; 15+ messages in thread From: Aidan Gauland @ 2011-03-19 1:16 UTC (permalink / raw) To: emacs-orgmode [-- Attachment #1: Type: text/plain, Size: 1398 bytes --] Hi, I use org-mode for my website, and I've noticed that when I go to publish the website, none of the files I have just edited are updated in the publishing directory. I have no idea why. Here is the elisp I evaluate to publish my website. (setq org-publish-project-alist '(("aidalgolland-orgfiles" :base-directory "~/doc-aidan/aidalgolland/main/" :publishing-directory "/ssh:aidan@nathan7.eu:public_html/aidalgolland/" :publishing-function org-publish-org-to-html :recursive t :base-extension "org" :section-numbers nil :table-of-contents nil :creator-info nil :language "en" :author "Aidan Gauland" :style "<link rel=\"stylesheet\" type=\"text/css\" href=\"/~aidan/aidalgolland/global.css\" />" :auto-preamble t :auto-postamble t) ("aidalgolland-static" :base-directory "~/doc-aidan/aidalgolland/main/" :publishing-directory "/ssh:aidan@nathan7.eu:public_html/aidalgolland/" :publishing-function org-publish-attachment :recursive t :base-extension "css\\|gz\\|bz2\\|lzma\\|jpg\\|gif\\|png\\|atom") ("aidalgolland" :components ("aidalgolland-orgfiles" "aidalgolland-static")))) (org-babel-lob-ingest "~/doc-aidan/aidalgolland/babel-lib.org") (org-publish "aidalgolland") (makunbound 'org-publish-project-alist) Can anyone help me with this? Thanks, Aidan Gauland [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 198 bytes --] ^ permalink raw reply [flat|nested] 15+ messages in thread
* Override export filename @ 2010-11-02 9:08 Aidan Gauland 2010-11-02 15:44 ` Giovanni Ridolfi 0 siblings, 1 reply; 15+ messages in thread From: Aidan Gauland @ 2010-11-02 9:08 UTC (permalink / raw) To: emacs-orgmode Hi, Is there an export option to specify the name of the file to which to export the org file? I use org-mode for my website and I need one page to have a different extension from .html. Thanks, Aidan Gauland ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Override export filename 2010-11-02 9:08 Override export filename Aidan Gauland @ 2010-11-02 15:44 ` Giovanni Ridolfi 2010-11-02 18:04 ` Aidan Gauland 0 siblings, 1 reply; 15+ messages in thread From: Giovanni Ridolfi @ 2010-11-02 15:44 UTC (permalink / raw) To: Aidan Gauland; +Cc: emacs-orgmode Aidan Gauland <aidalgol@no8wireless.co.nz> writes: > Is there an export option to specify the name of the file to which to > export the org file? for documents: #+TITLE: and, for subtrees :PROPERTIES: :EXPORT_TITLE: :END: cheers, Giovanni ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Override export filename 2010-11-02 15:44 ` Giovanni Ridolfi @ 2010-11-02 18:04 ` Aidan Gauland [not found] ` <aidalgol@no8wireless.co.nz> 0 siblings, 1 reply; 15+ messages in thread From: Aidan Gauland @ 2010-11-02 18:04 UTC (permalink / raw) To: Giovanni Ridolfi; +Cc: emacs-orgmode [-- Attachment #1.1: Type: text/plain, Size: 455 bytes --] On Tue, Nov 02, 2010 at 04:44:11PM +0100, Giovanni Ridolfi wrote: > Aidan Gauland <aidalgol@no8wireless.co.nz> writes: > > > Is there an export option to specify the name of the file to which to > > export the org file? > > for documents: > #+TITLE: This doesn't seem to allow me to specify the filename. For example, the file... #+TITLE: bar.goo * A heading foo foo ...is exported (as HTML) to foo.html, not bar.goo. --Aidan [-- Attachment #1.2: Digital signature --] [-- Type: application/pgp-signature, Size: 198 bytes --] [-- Attachment #2: Type: text/plain, Size: 201 bytes --] _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode ^ permalink raw reply [flat|nested] 15+ messages in thread
[parent not found: <aidalgol@no8wireless.co.nz>]
* Re: Override export filename [not found] ` <aidalgol@no8wireless.co.nz> @ 2010-11-02 18:35 ` Nick Dokos 2010-11-05 0:57 ` Aidan Gauland 2011-03-19 1:33 ` org-publish not publishing changed files Nick Dokos 1 sibling, 1 reply; 15+ messages in thread From: Nick Dokos @ 2010-11-02 18:35 UTC (permalink / raw) To: Giovanni Ridolfi, emacs-orgmode; +Cc: nicholas.dokos Aidan Gauland <aidalgol@no8wireless.co.nz> wrote: > On Tue, Nov 02, 2010 at 04:44:11PM +0100, Giovanni Ridolfi wrote: > > Aidan Gauland <aidalgol@no8wireless.co.nz> writes: > > > > Is there an export option to specify the name of the file to which to > > > export the org file? > > > for documents: > > #+TITLE: > > This doesn't seem to allow me to specify the filename. For example, > the file... > > #+TITLE: bar.goo > > * A heading > foo foo > > ..is exported (as HTML) to foo.html, not bar.goo. > If you just need a different extension, I think this works: --8<---------------cut here---------------start------------->8--- #+BIND: org-export-html-extension "goo" * foo foo * bar bar --8<---------------cut here---------------end--------------->8--- and there might be a higher-level way to do that too; e.g. if you are publishing a project, you can set the :html-extension property, but that is probably going to affect more than the one file. Also, I don't know of a way to change the base filename however, and cursory examination of the code leads me to believe that it is not possible currently. HTH, Nick ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Override export filename 2010-11-02 18:35 ` Nick Dokos @ 2010-11-05 0:57 ` Aidan Gauland 0 siblings, 0 replies; 15+ messages in thread From: Aidan Gauland @ 2010-11-05 0:57 UTC (permalink / raw) To: emacs-orgmode Nick Dokos <nicholas.dokos <at> hp.com> writes: > If you just need a different extension, I think this works: > > --8<---------------cut here---------------start------------->8--- > #+BIND: org-export-html-extension "goo" > > * foo > foo > > * bar > bar > --8<---------------cut here---------------end--------------->8--- Yup, that works perfectly. Thanks! --Aidan ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: org-publish not publishing changed files [not found] ` <aidalgol@no8wireless.co.nz> 2010-11-02 18:35 ` Nick Dokos @ 2011-03-19 1:33 ` Nick Dokos 2011-03-19 2:19 ` Suvayu Ali 2011-03-22 2:00 ` Aidan Gauland 1 sibling, 2 replies; 15+ messages in thread From: Nick Dokos @ 2011-03-19 1:33 UTC (permalink / raw) To: emacs-orgmode; +Cc: nicholas.dokos Aidan Gauland <aidalgol@no8wireless.co.nz> wrote: > Hi, > > I use org-mode for my website, and I've noticed that when I go to > publish the website, none of the files I have just edited are updated > in the publishing directory. I have no idea why. Here is the elisp I > evaluate to publish my website. > > (setq > org-publish-project-alist > '(("aidalgolland-orgfiles" > :base-directory "~/doc-aidan/aidalgolland/main/" > :publishing-directory "/ssh:aidan@nathan7.eu:public_html/aidalgolland/" > :publishing-function org-publish-org-to-html > :recursive t > :base-extension "org" > :section-numbers nil > :table-of-contents nil > :creator-info nil > :language "en" > :author "Aidan Gauland" > :style "<link rel=\"stylesheet\" type=\"text/css\" href=\"/~aidan/aidalgolland/global.css\" />" > :auto-preamble t > :auto-postamble t) > > ("aidalgolland-static" > :base-directory "~/doc-aidan/aidalgolland/main/" > :publishing-directory "/ssh:aidan@nathan7.eu:public_html/aidalgolland/" > :publishing-function org-publish-attachment > :recursive t > :base-extension "css\\|gz\\|bz2\\|lzma\\|jpg\\|gif\\|png\\|atom") > > ("aidalgolland" :components ("aidalgolland-orgfiles" "aidalgolland-static")))) > > (org-babel-lob-ingest "~/doc-aidan/aidalgolland/babel-lib.org") > (org-publish "aidalgolland") > > (makunbound 'org-publish-project-alist) > > Can anyone help me with this? > > Thanks, > Aidan Gauland org uses timestamps to figure out which files need publishing (see section 13.4 of the Org manual) and they may have gotten curdled somehow. You can force publication by giving a second argument to org-publish (if you called it interactively, you could do that by giving it a prefix arg): (org-publish "aidalgolland" t) Or you can try getting rid of the timestamps (they are stored in the directory named in the variable org-publish-timestamp-directory (by default "~/.org-timestamps/") and publish again. If you can figure out *why* they got out of sync, that would be a bonus and worth a post here, particularly if you can identify a bug in the code. Nick ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: org-publish not publishing changed files 2011-03-19 1:33 ` org-publish not publishing changed files Nick Dokos @ 2011-03-19 2:19 ` Suvayu Ali 2011-03-20 11:30 ` David Maus 2011-03-22 2:00 ` Aidan Gauland 1 sibling, 1 reply; 15+ messages in thread From: Suvayu Ali @ 2011-03-19 2:19 UTC (permalink / raw) To: emacs-orgmode On Fri, 18 Mar 2011 21:33:04 -0400 Nick Dokos <nicholas.dokos@hp.com> wrote: > If you can figure out *why* they got out of sync, that would be > a bonus and worth a post here, particularly if you can identify > a bug in the code. I think there was a post sometime earlier where the OP faced this issue because his setup used symlinks. The timestamps of the symlinks didn't change so the publishing didn't happen. -- Suvayu Open source is the future. It sets us free. ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: org-publish not publishing changed files 2011-03-19 2:19 ` Suvayu Ali @ 2011-03-20 11:30 ` David Maus 2011-03-20 11:47 ` Suvayu Ali 0 siblings, 1 reply; 15+ messages in thread From: David Maus @ 2011-03-20 11:30 UTC (permalink / raw) To: Suvayu Ali; +Cc: emacs-orgmode [-- Attachment #1: Type: text/plain, Size: 704 bytes --] At Fri, 18 Mar 2011 19:19:50 -0700, Suvayu Ali wrote: > > On Fri, 18 Mar 2011 21:33:04 -0400 > Nick Dokos <nicholas.dokos@hp.com> wrote: > > > If you can figure out *why* they got out of sync, that would be > > a bonus and worth a post here, particularly if you can identify > > a bug in the code. > > I think there was a post sometime earlier where the OP faced this issue > because his setup used symlinks. The timestamps of the symlinks didn't > change so the publishing didn't happen. The issue with publishing symlinked files was fixed in Januar by b4979a86ca10d058a780440e88c5a3e33c1adff5. Best, -- David -- OpenPGP... 0x99ADB83B5A4478E6 Jabber.... dmjena@jabber.org Email..... dmaus@ictsoc.de [-- Attachment #2: Type: application/pgp-signature, Size: 230 bytes --] ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: org-publish not publishing changed files 2011-03-20 11:30 ` David Maus @ 2011-03-20 11:47 ` Suvayu Ali 0 siblings, 0 replies; 15+ messages in thread From: Suvayu Ali @ 2011-03-20 11:47 UTC (permalink / raw) To: David Maus; +Cc: emacs-orgmode On Sun, 20 Mar 2011 12:30:32 +0100 David Maus <dmaus@ictsoc.de> wrote: > At Fri, 18 Mar 2011 19:19:50 -0700, > Suvayu Ali wrote: > > > > I think there was a post sometime earlier where the OP faced this > > issue because his setup used symlinks. The timestamps of the > > symlinks didn't change so the publishing didn't happen. > > The issue with publishing symlinked files was fixed in Januar by > b4979a86ca10d058a780440e88c5a3e33c1adff5. > Thanks for correcting me David. :) > Best, > -- David -- Suvayu Open source is the future. It sets us free. ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: org-publish not publishing changed files 2011-03-19 1:33 ` org-publish not publishing changed files Nick Dokos 2011-03-19 2:19 ` Suvayu Ali @ 2011-03-22 2:00 ` Aidan Gauland 2011-03-22 6:18 ` Nick Dokos 1 sibling, 1 reply; 15+ messages in thread From: Aidan Gauland @ 2011-03-22 2:00 UTC (permalink / raw) To: emacs-orgmode Nick Dokos <nicholas.dokos <at> hp.com> writes: > org uses timestamps to figure out which files need publishing > (see section 13.4 of the Org manual) and they may have gotten > curdled somehow. You can force publication by giving a second > argument to org-publish (if you called it interactively, you > could do that by giving it a prefix arg): > > (org-publish "aidalgolland" t) > > Or you can try getting rid of the timestamps (they are stored > in the directory named in the variable org-publish-timestamp-directory > (by default "~/.org-timestamps/") and publish again. > > If you can figure out *why* they got out of sync, that would be > a bonus and worth a post here, particularly if you can identify > a bug in the code. How can I get the timestamps in a more human-readable format? I keep having this problem (and no symlinks involved) and keep having to wipe the timestamps directory (a royal nuisance). --Aidan ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Re: org-publish not publishing changed files 2011-03-22 2:00 ` Aidan Gauland @ 2011-03-22 6:18 ` Nick Dokos 2011-03-22 7:32 ` Aidan Gauland 0 siblings, 1 reply; 15+ messages in thread From: Nick Dokos @ 2011-03-22 6:18 UTC (permalink / raw) To: Aidan Gauland; +Cc: nicholas.dokos, emacs-orgmode Aidan Gauland <aidalgol@no8wireless.co.nz> wrote: > Nick Dokos <nicholas.dokos <at> hp.com> writes: > > org uses timestamps to figure out which files need publishing > > (see section 13.4 of the Org manual) and they may have gotten > > curdled somehow. You can force publication by giving a second > > argument to org-publish (if you called it interactively, you > > could do that by giving it a prefix arg): > > > > (org-publish "aidalgolland" t) > > > > Or you can try getting rid of the timestamps (they are stored > > in the directory named in the variable org-publish-timestamp-directory > > (by default "~/.org-timestamps/") and publish again. > > > > If you can figure out *why* they got out of sync, that would be > > a bonus and worth a post here, particularly if you can identify > > a bug in the code. > > How can I get the timestamps in a more human-readable format? I keep > having this problem (and no symlinks involved) and keep having to wipe > the timestamps directory (a royal nuisance). > Doesn't the prefix argument work? C-u C-c C-e followed by F or P or X or E should republish whatever you specified (file, current project, some project or all projects resp.), no matter what the cache says. Nick ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: org-publish not publishing changed files 2011-03-22 6:18 ` Nick Dokos @ 2011-03-22 7:32 ` Aidan Gauland 2011-03-22 14:17 ` Nick Dokos 0 siblings, 1 reply; 15+ messages in thread From: Aidan Gauland @ 2011-03-22 7:32 UTC (permalink / raw) To: emacs-orgmode Nick Dokos <nicholas.dokos <at> hp.com> writes: > > How can I get the timestamps in a more human-readable format? I keep > > having this problem (and no symlinks involved) and keep having to wipe > > the timestamps directory (a royal nuisance). > > Doesn't the prefix argument work? C-u C-c C-e followed by F or P or X or E > should republish whatever you specified (file, current project, some project > or all projects resp.), no matter what the cache says. Yes it does. Sorry, I should have worded that differently. I meant that I have been repeatedly wiping ~/.org-timestamps/ in hopes that it will not get screwed up again and think none of my files have changed, and never re-publishes changed files (after an initial org-publish operation). I think I have run into a bug in org-mode and I really want to track it down, so I thought the best place to start would be to look at what the timestamps are (in a human-readable format). --Aidan ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Re: org-publish not publishing changed files 2011-03-22 7:32 ` Aidan Gauland @ 2011-03-22 14:17 ` Nick Dokos 2011-04-01 19:56 ` Aidan Gauland 0 siblings, 1 reply; 15+ messages in thread From: Nick Dokos @ 2011-03-22 14:17 UTC (permalink / raw) To: Aidan Gauland; +Cc: nicholas.dokos, emacs-orgmode Aidan Gauland <aidalgol@no8wireless.co.nz> wrote: > > Yes it does. Sorry, I should have worded that differently. I meant > that I have been repeatedly wiping ~/.org-timestamps/ in hopes that it > will not get screwed up again and think none of my files have changed, > and never re-publishes changed files (after an initial org-publish > operation). I think I have run into a bug in org-mode and I really > want to track it down, so I thought the best place to start would be > to look at what the timestamps are (in a human-readable format). > OK - thanks. I started taking a look at the code, but I'm not getting anywhere fast, so the more eyes we can have on it the better. I believe what happens is that the in-memory cache is initialized from the files in ~/.org-timestamps the first time that you try to publish (I'm not sure yet when the cache is flushed back out to the files yet). Here is one of the timestamp files: ,---- | (setq org-publish-cache (make-hash-table :test 'equal :weakness nil :size 100)) | (puthash ":project:" "worg-org-faq" org-publish-cache) | (puthash ":cache-file:" "/home/nick/.org-timestamps/worg-org-faq.cache" org-publish-cache) | (puthash "Xd2e1407553750278e966c6cda86f154ffa648149" 1299616514 org-publish-cache) `---- It's a simple key-value store: (puthash key value table) does the obvious thing, so the timestamp here is 1299616514 for the object with key Xd2e1407553750278e966c6cda86f154ffa648149. The timestamp is the ctime of the file, obtained by calling file-attributes, getting the 5th element, the last modification time. This is returned as a list of two integers (high, low16) which are then combined into a single integer: that's the time since 1970-01-01:00:00:00, the usual Unix time. In the above case, I calculate as follows (lsh is a shift function - (lsh val 16) shifts left by 16, (lsh val -16) shifts right by 16): high bits: (lsh 1299616514 -16) -> 19830 low bits: (- 1299616514 (lsh 19830 16)) -> 37634 So encoded time is (19830 37364) Decoded time: (decode-time '(19830 37634)) -> (14 35 15 8 3 2011 2 nil -18000) that is 14:35:15 08-03-2011 dow=2(=Tuesday) dst=nil(= no dst - the switch happened later) zone=-18000 (in seconds - that is -5GMT in hours). So you might try the following simple helper function: --8<---------------cut here---------------start------------->8--- (defun org-ts-to-hr (ts) (let* ((high (lsh ts -16)) (low (- ts (lsh high 16)))) (decode-time (list high low)))) --8<---------------cut here---------------end--------------->8--- (org-ts-to-hr 1299616514) -> (14 35 15 8 3 2011 2 nil -18000) Note that it may not be the timestamp itself that's at fault: it may be the key. If we calculate a key and go look in the cache and don't find it, then the file is considered out of date. But I guess this is the opposite behavior of what you see. Never mind... HTH, Nick ^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: org-publish not publishing changed files 2011-03-22 14:17 ` Nick Dokos @ 2011-04-01 19:56 ` Aidan Gauland 0 siblings, 0 replies; 15+ messages in thread From: Aidan Gauland @ 2011-04-01 19:56 UTC (permalink / raw) To: emacs-orgmode Nick Dokos <nicholas.dokos <at> hp.com> writes: > Aidan Gauland <aidalgol <at> no8wireless.co.nz> wrote: > > Yes it does. Sorry, I should have worded that differently. I meant > > that I have been repeatedly wiping ~/.org-timestamps/ in hopes that it > > will not get screwed up again and think none of my files have changed, > > and never re-publishes changed files (after an initial org-publish > > operation). I think I have run into a bug in org-mode and I really > > want to track it down, so I thought the best place to start would be > > to look at what the timestamps are (in a human-readable format). > > > > OK - thanks. I started taking a look at the code, but I'm not getting > anywhere fast, so the more eyes we can have on it the better. Actually, we can forget about the timestamps. I finally figured out what circumstances under which this bug happens: I am trying to export from a system where some of the symlinks in the project are broken. Here's my setup: I sync my home directory on my laptop and desktop computers using Unison. In my project, I have symlinks to files in ~/images/, but since my laptop hard drive has less capacity than the one in my desktop, I only keep ~/images/ on my desktop. As a result of this setup, some symlinks in my org-mode project are broken on my laptop. When I publish my project on my desktop, where no symlinks are broken, org-publish behaves as expected; when I publish the same project on my laptop, where some symlinks are broken, org-publish appears to succeed, but publishes no changes. I am really sorry for such a delayed response, but my university semester started up again, which has been really hectic because of the Feburary Christchurch earthquake. Kind regards, Aidan Gauland ^ permalink raw reply [flat|nested] 15+ messages in thread
end of thread, other threads:[~2011-04-01 19:56 UTC | newest] Thread overview: 15+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2011-03-19 1:16 org-publish not publishing changed files Aidan Gauland -- strict thread matches above, loose matches on Subject: below -- 2010-11-02 9:08 Override export filename Aidan Gauland 2010-11-02 15:44 ` Giovanni Ridolfi 2010-11-02 18:04 ` Aidan Gauland [not found] ` <aidalgol@no8wireless.co.nz> 2010-11-02 18:35 ` Nick Dokos 2010-11-05 0:57 ` Aidan Gauland 2011-03-19 1:33 ` org-publish not publishing changed files Nick Dokos 2011-03-19 2:19 ` Suvayu Ali 2011-03-20 11:30 ` David Maus 2011-03-20 11:47 ` Suvayu Ali 2011-03-22 2:00 ` Aidan Gauland 2011-03-22 6:18 ` Nick Dokos 2011-03-22 7:32 ` Aidan Gauland 2011-03-22 14:17 ` Nick Dokos 2011-04-01 19:56 ` Aidan Gauland
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).