#arch-linux #lock-files #pkgbuild #tree #supply-chain-security #dont #upstream

app updlockfiles

Manage lockfiles in PKGBUILDs for upstreams that don’t ship them, updpkgsums for dependency trees (Arch Linux tooling)

2 releases

0.1.1 Jul 3, 2024
0.1.0 Oct 16, 2022

#118 in Unix APIs

Download history 16/week @ 2024-07-30 6/week @ 2024-09-10 3/week @ 2024-09-17 18/week @ 2024-09-24 7/week @ 2024-10-01

70 downloads per month

GPL-3.0 license

36KB
125 lines

updlockfiles

Manage lockfiles for packages that don't ship any upstream. Like updpkgsums but for 3rd party dependency trees.

If you're not actively maintaining Arch Linux packages you likely don't need this tool.

Getting started

Add a function like this to your PKGBUILD:

updlockfiles() {
  cd ${pkgname}
  rm -f composer.lock
  composer update
  cp composer.lock "${outdir}/"
}

This works for arbitrary files, just make sure the files you want copied back need to be copied into $outdir.

Next run this command (no arguments needed, the default should just work):

updlockfiles

Finally add the new file to your source array (and make sure it's part of your next commit!):

source=("git+https://github.com/vimeo/psalm.git#commit=${_commit}"
        "composer.lock")

Update the checksums for content pinning:

updpkgsums

Update a lockfile

If the initial setup was done before you can generate a new lockfile of the latest patch level like this:

updlockfiles

License

GPLv3+

Dependencies

~3–12MB
~152K SLoC