summaryrefslogtreecommitdiff
path: root/build-all-with-docker
diff options
context:
space:
mode:
authorErich Eckner <erich.eckner.ext@bestsecret.com>2024-08-02 12:47:38 +0200
committerErich Eckner <erich.eckner.ext@bestsecret.com>2024-08-02 12:47:38 +0200
commit315f7a9d815374c047ad5e1ca32f040df507e035 (patch)
treecb1025ff0a806ba28beee196e11475bdc6a0977a /build-all-with-docker
parent0955ecccb47fc21c4bb172140aed96496187f88a (diff)
downloadarchlinuxewe-315f7a9d815374c047ad5e1ca32f040df507e035.tar.xz
build-all-with-docker: do lock, we do not want to run multiple docker builds for the same package
Diffstat (limited to 'build-all-with-docker')
-rwxr-xr-xbuild-all-with-docker6
1 files changed, 6 insertions, 0 deletions
diff --git a/build-all-with-docker b/build-all-with-docker
index fbc75020c..1aa62d026 100755
--- a/build-all-with-docker
+++ b/build-all-with-docker
@@ -2,6 +2,12 @@
cd "$(dirname "$(readlink -e "$0")")"
+exec 9> build-all-with-docker.lock
+if ! flock -n 9; then
+ >&2 echo 'another build-all-with-docker still holds the lock'
+ exit 1
+fi
+
if [ "x$1" = 'x--pull' ]; then
shift
if ! git pull --ff-only; then