#!/usr/bin/env bash { set -euE COMMIT="${1:-systemd/master}" workdir=$PWD/workdir mkdir -p -- "$workdir" gitget bare https://git.parabola.nu/~lukeshu/systemd.git "$workdir/systemd.git" ./mkosi \ --include-pkg='base' \ --module=mkosi.d/systemd-libretools.sh \ --module=mkosi.d/systemd-runscript.sh \ --include-dir="$workdir/systemd.git:/home/runscript/packages/srcdest/systemd" \ --include-dir="abs/systemd-232:/home/runscript/packages/abs/systemd-232" \ --include-dir="abs/systemd:/home/runscript/packages/abs/systemd" \ "${workdir}/build.raw" ./runscript "${workdir}/build.raw" <<-EOF #!/usr/bin/env bash set -ex cd ~/packages/abs/systemd-232 sudo libremakepkg cd ~/packages/abs/systemd sed 's/@COMMIT@/${COMMIT}/' < PKGBUILD.in > PKGBUILD sudo libremakepkg EOF }