`hampackcheck packages` (and `make check-packages`) checks that every package in packages.conf is in the repos or on the AUR and every Flatpak is on Flathub, and fails if any is missing or couldn't be checked. Names only provided by another package pass with a note. New tests cover hampackcheck's version comparisons and package check, and check compile.conf, binaries.conf, packages.conf and the desktop files for missing or misspelt fields and paths that don't exist. A Gitea workflow runs lint and tests on every push and pull request, and the package check on those and weekly. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
26 lines
710 B
Makefile
26 lines
710 B
Makefile
# HamPack development tasks
|
|
# make lint - shellcheck every script
|
|
# make test - run the bats tests in tests/
|
|
# make check-packages - check every package and Flatpak in packages.conf can
|
|
# still be installed (needs the network; run `pacman -Sy` first)
|
|
# make hooks - run `make lint test` before each commit
|
|
|
|
SCRIPTS := install.sh update.sh lib.sh install-binaries.sh install-compiled.sh \
|
|
install-flatpaks.sh install-windows-apps.sh patch-potacat.sh hampackcheck hampackremove
|
|
|
|
.PHONY: check lint test check-packages hooks
|
|
|
|
check: lint test
|
|
|
|
lint:
|
|
shellcheck -x $(SCRIPTS)
|
|
|
|
test:
|
|
bats tests/
|
|
|
|
check-packages:
|
|
./hampackcheck packages
|
|
|
|
hooks:
|
|
git config core.hooksPath .githooks
|