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

Add new 'last-edit' tour versioning scheme. #252

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

trcoffman
Copy link

@trcoffman trcoffman commented Jul 28, 2022

The Current Commit versioning strategy for tours is quite brittle, because it is
based on commit hashes. The moment history gets rewritten by a rebase, the tour
becomes untethered from the commit that we are trying to attach it to, because
the commit hash that's recorded in the tour file no longer exists.

Also, the Current Commit versioning strategy means that a tour commit must be in a
separate commit, becuase the commit that it's attached to must already exist so
that its hash can be recorded in the ref field of the tour.

Introduce a 'last-edit' versioning scheme. If the value of the ref is
'last-edit', then the tour is associated with the most recent commit that
modifies the tour file.

This will enable a code change and a tour which documents the code change to
exist in the same commit. If during code review, the git history is rewritten by
a rebase, the tour will still properly be associated with the correct commit.
This should provide a far more robust and simpler user experience than the
Current Commit versioning strategy.

@ghost
Copy link

ghost commented Jul 28, 2022

CLA assistant check
All CLA requirements met.

The Current Commit versioning strategy for tours is quite brittle, because it is
based on commit hashes. The moment history gets rewritten by a rebase, the tour
becomes untethered from the commit that we are trying to attach it to, because
the commit hash that's recorded in the tour file no longer exists.

Also, the Current Commit versioning strategy means that a tour commit must be in a
separate commit, becuase the commit that it's attached to must already exist so
that its hash can be recoreded in the `ref` field of the tour.

Introduce a 'last-edit' versioning scheme. If the value of the ref is
`'last-edit'`, then the tour is associated with the most recent commit that
modifies the tour file.

This will enable a code change and a tour which documents the code change to
exist in the same commit. If during code review, the git history is rewritten by
a rebase, the tour will still properly be associated with the correct commit.
This should provide a far more robust and simpler user experience than the
Current Commit versioning strategy.
@trcoffman trcoffman marked this pull request as ready for review August 29, 2022 20:47
@trcoffman
Copy link
Author

It would be wonderful to get a review on this PR. I would appreciate it greatly.

@huyz
Copy link

huyz commented Aug 8, 2023

This sounds like a good idea.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants