[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [FR] Make notion of "modification time" configurable during publishi
From: |
Ihor Radchenko |
Subject: |
Re: [FR] Make notion of "modification time" configurable during publishing |
Date: |
Fri, 22 Sep 2023 09:41:15 +0000 |
Suhail Singh <suhailsingh247@gmail.com> writes:
>> The new suggested feature is (optionally) using last git commit time
>> instead of file modification time.
>
> The requested feature is for the notion of "modification time" to be
> configurable by the user. Even in the specific situation quoted above,
> different users may desire different alternative notions of
> "modification time". For instance,
>
> - the value of the DATE keyword
> - if using git as vc, the "git author date"
> - if using git as vc, the "git commit date"
I am a bit confused. What do you mean by "git author date" and "git
commit date"?
> It would help for the notion of "modification time" (currently
> hard-coded as file-attribute-modification-time ) to be configurable in
> the following functions:
>
> - org-publish-cache-mtime-of-src: this is used to decide whether or not
> a particular file needs to be republished. I.e., the function at the
> heart of the motivating situation discussed during the meetup.
I think that we should use an alternative approach. Both "git time" and
"fs time" are only an approximation. The true decision to re-publish an
article should be triggered by article text being modified. So, we may
better decide based on the file text hash, not the modification times.
--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>