[Request for comments]: Site Versioning#1870
Draft
kaixin-hc wants to merge 38 commits into
Draft
Conversation
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What is the purpose of this pull request?
MVP for #1009
Overview of changes:
TODO:
Anything you'd like to highlight / discuss:
Benefits of the solution proposed in this PR
Potential Drawbacks
Thoughts
CAVEATS:
Testing instructions:
markbind archive <versionName> [versionFolderName]--> builds and saves the site in a given version and folder name.markbind archive <versionName>builds and saves the site with a given version name in a folder called versionAccess the site by manually appending
<versionFolderName>/<version name>after the baseURL in the deployed site.Proposed commit message: (wrap lines at 72 characters)
Implement a basic versioning CLI command
Site versioning is key for documentation use, and education websites
may want to keep past versions for archival purposes as well.
Let's implement a markbind-cli command, markbind archive, to allow
users to easily version their website. When markbind build/serve is run,
all links within the versioned site will point to their versioned equivalent.
Checklist: ☑️
Stretch goals/future improvements
Additional CLI commands to support renaming, moving versions, and deleting versions, so that users do not ever need to modify
versions.jsonmanually.Support live preview updating when the versions property of site.json is changed.
Editing of previous versions. My preferred solution is saving versions in separate branches, holding all files, except previously archived versions. Update the deployed files by navigating to a separate branch (and take advantage of git; like say if you fix a bug which affects all versions, you can cherrypick the commit over to the versioned branch). This will also support reverting to previous versions (working and deploying off of the versioned branch...?). caveat: this is dependent on git.
Front end component to easily navigate between versioned branches? Personally leaning towards a bannet, like in the 3281 site(note: banner component does not exist), but a component in the footer with a default message that you can change (like the "generated by markbind" message) might be sufficiently versatile to work as a default implementation. We could also have an auto-generated dropdown component which users can place in their navbar as desired. Key difficulty: making it versatile and customisable for all types of sites while also working "out of the box", since websites don't need to follow any set format, this may be difficult.