Hello, David Trudgett <david.trudg...@eclecticse.com.au> writes:
> Reproduce: > > In an Org mode file, add a #+DATE tag as follows: > > #+DATE: First published: 1 February 2014 > > Then initiate a project publish, which publishes (by default) only > changed files. A date such as the above will not be parsed, so > ox-publish.el will always publish it, even though it has not changed. > Using instead a parsable date format (such as 2014-02-01), this date will be > recognised, and will result in the file never being published, because > it is treating the date as a modification date instead of a creation date. > > Desired Behaviour: > > ox-publish.el, in function ORG-PUBLISH-FIND-DATE should not be using > this date to detect modifications, as it will never change, and no > modifications will be detected for publishing. I don't understand how you come to this conclusion. The function responsible for deciding if a file should be published is `org-publish-cache-file-needs-publishing'. It doesn't call `org-publish-find-date', but `org-publish-cache-ctime-of-src'. The latter only uses `file-attribute-modification-time'. IOW, I think the file is published because you modified since last publishing. WDYT? Regards, -- Nicolas Goaziou