Closed OpenBagTwo closed 9 months ago
So pygit2's write_archive
method only supports tarfiles. This means that in order to support zip gsb
will either:
ZipFile
that implements the tarfile
methods called by write_archive
write_archive
I was originally thinking about (2), but honestly that's going to be extremely brittle unless I pin the version of pygit2.
GIVEN Steve wants to export a specific backup of a specific save state (
my-save
) at a specific time AND he doesn't want that export to include the full history attachedWHEN he runs the command
gsb export my-save [tag-name-or-commit-hash]
(or omits that argument to just use the current state)THEN a file should be generated in the current working directory named
my-save.<tag-name-or-commit-hash>.zip
* containing a static snapshot of the specified backupSO that he can take that export and use it on another machine, upload it to a bug-tracker for diagnostics, safely dissect it, or put it into some cold storage medium without having to run the
git
command manuallyNotes
git archive
--filename
and--format
(passing through to--output
and--format
, respectively.tar.xz
by default