pristine-lfs(1)
πΈ NAME πΈ
pristine-lfs β store pristine tarballs in Git LFS π
okay so this is the pristine-lfs(1) page, from the Git manual, and honestly? it's lowkey iconic. it does exactly what the name says and it's gonna make your Debian packaging life so much easier, bestie, no cap.
β¨ SYNOPSIS β¨
pristine-lfs [-h|--help]
pristine-lfs [OPTIONS] commit [OPTIONS] (--auto | tarball)
pristine-lfs [OPTIONS] import-dsc [OPTIONS] dsc
pristine-lfs [OPTIONS] checkout [-o outdir] tarball
pristine-lfs [OPTIONS] list
pristine-lfs [OPTIONS] verify tarball
π¦ DESCRIPTION π¦
so here's the tea: pristine-lfs can store pristine upstream tarballs in Git by leveraging Git LFS. the way it works is so clever β instead of yeeting those potentially huge tarballs into your Git repo as blobs (π the repo size), Git LFS only stores specially prepared metadata in the repository, while the actual file contents live out of band on a Git LFS server. main character storage strategy fr.
using pristine-lfs lets Debian packages be built entirely using sources in version control, with zero need to keep copies of upstream tarballs lying around. obsessed. β¨
pristine-lfs supports tarballs compressed with any compressor. yes, any. slay.
Tarball signatures (any files ending with .asc) are committed as they are, without utilising the Git LFS mechanisms. they just vibe in the repo. π
π COMMANDS π
commit
pristine-lfs commit [-b BRANCH] [-m MESSAGE] [--force-overwrite] tarball [upstream]
pristine-lfs commit stores the specified tarball using Git LFS, and commits its metadata to version control. then later, the pristine-lfs checkout command can be used to recreate the original tarball based on the information stored in Git LFS. π
heads up bestie: the data are not submitted to the server until a git push command is issued. so don't panic if nothing's uploaded yet.
the upstream parameter is ignored β it's only supported for compatibility with pristine-tar. (we keep it around for the old heads, periodt.)
if a tarball with a different hash has already been committed, it will only be overwritten if --force-overwrite is specified. β οΈ
import-dsc
pristine-lfs import-dsc [-b BRANCH] [-m MESSAGE] [--force-overwrite] [--full] path-to-dsc
import tarballs and their signatures from a .dsc file of a Debian source package. π§
if --full is specified, it also imports the Debian packaging and the .dsc file itself.
if a tarball with a different hash has already been committed, it will only be overwritten if --force-overwrite is specified. same energy as above. β οΈ
checkout
pristine-lfs checkout [-b BRANCH] [-o outdir] [--full] (--auto | tarball)
regenerate a copy of the specified tarball using information previously saved in version control by pristine-lfs commit. it's giving restoration arc. π
by default, the tarball is placed in the current directory. if outdir is specified, the file is created in that directory.
for compatibility with pristine-tar, tarball can include the path to the output directory; this takes precedence over the outdir option. so if they're beefing, the path inside tarball wins. π«Ά
if --auto is specified, pristine-lfs will consult a file named debian/changelog, and if it exists, will check out all tarballs associated with the latest version the changelog mentions. auto-pilot mode: engaged. β¨
if --full is specified and a .dsc file is requested, it also checks out the Debian packaging and the .dsc file itself.
list
pristine-lfs list [-b BRANCH]
list tarballs that pristine-lfs is able to checkout from version control. it's basically the menu. π
verify
pristine-lfs verify [-b BRANCH] tarball
verify whether an existing tarball matches the one that has been committed to version control. vibe check for your tarballs, literally. π₯
π OPTIONS π
-m MESSAGE,--message=MESSAGEβ use the given MESSAGE as the commit message for the metadata commits. applies to thecommitandimport-dsccommands. and here's the cute part:%sin the commit message gets replaced by a comma-separated list of files committed. β¨, so custom, so convenient.-b BRANCH,--branch BRANCHβ the branch to store Git LFS metadata on. pick your lane. π-v,--verboseβ be more verbose. tell me everything, bestie. π£οΈ--debugβ show all sorts of debugging information. implies--verbose. it's giving over-share and we love that for it. π-hβ show this help message and exit. the classic escape hatch. π
πΈ ENVIRONMENT πΈ
TMPDIRβ specifies a location to place temporary files, other than the default. if your/tmpis a mess (relatable), point it somewhere else. π
π SEE ALSO π
π AUTHOR π
Andrej Shadura <andrew.shadura@collabora.co.uk>
and that's the whole page, bestie! π¦ this one's from the 20210222.0 release, dated 2021-02-22. now go store those tarballs out of band and live your best Git LFS life. you ate. πβ¨
π¦ where this page comes from
- ubuntu resolute: pristine-lfs 20241219.0-2 Β· GPL-2.0-or-later
- ubuntu stonking: pristine-lfs 20241219.0-2 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms