Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Decide whether to drop datetime information #19

Closed
uliska opened this issue Mar 4, 2020 · 1 comment
Closed

Decide whether to drop datetime information #19

uliska opened this issue Mar 4, 2020 · 1 comment
Labels
enhancement New feature or request

Comments

@uliska
Copy link
Contributor

uliska commented Mar 4, 2020

As discussed in #12 (comment) retrieving the last-modification timestamp for a given page doesn't actually have a use case within the context of the plugin. Dropping support for it (also from the resulting git_author dictionary in the page context) would make implementation more straightforward.

However, if we decide to keep the Git classes proposed in #12 and to merge the plugin with mkdocs-revision-date-localized it makes sense to also determine that value from the git blame data.

So: if the two decisions are not taken support for that value should be removed (from Commit._populate() or probably Page._process_git_blame() by then).

@timvink timvink added the enhancement New feature or request label Mar 4, 2020
@timvink
Copy link
Owner

timvink commented Mar 5, 2020

We have decided to keep the Git classes, and I updated the #16, as it makes sense to combine both git date and author functionality in the future.

There is one more consideration. For date, currently we use git log -n 1 -p <file path> to get the latest commit on a file. Replacing that with parsing git blame --porcelain for the commit with the most recent date seems like we're doing the same thing, but I'm not sure how if there are differences when shallow clones (git clone --depth 1) are made. (background on shallow clone problem in timvink/mkdocs-git-revision-date-localized-plugin#10))

For now, I see no reason yet to drop datetime information from the codebase.

@timvink timvink closed this as completed Mar 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants