From 11abbcbade2007fe352716161ff9d09843b9503c Mon Sep 17 00:00:00 2001 From: Harald Pfeiffer Date: Mon, 21 Mar 2022 12:07:33 +0100 Subject: check for DFDISTRIB, less output on rm --- Makefile | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 0a35cc0..787e2f4 100644 --- a/Makefile +++ b/Makefile @@ -1,11 +1,14 @@ VERSION = 3.82 -all: tempdirs tarball removedirs distrib removetar +all: complete + +# checkenv is redundant here but prevents execution of anything before failing +complete: checkenv tempdirs tarball removedirs distrib removetar tarball: rsync -avu bin .bash .bash_profile .bashrc .flake8 .gitconfig .perlcriticrc .profile .pylintrc .tmux.conf .tmux.conf.local tmux-gpakosz tmux-yank --exclude=.git --exclude=.gitattributes --exclude=.github --exclude=.gitignore --exclude='LICENSE*' --exclude='README*' distribute/tar/ tar -C distribute/tar -cvJf dotfiles.tar.xz . - rm -vrf distribute/tar + rm -rf distribute/tar tempdirs: @mkdir -pv distribute/tar @@ -13,8 +16,11 @@ tempdirs: removedirs: rm -rf distribute/tar -distrib: +distrib: checkenv ansible-playbook distrib.yml +checkenv: + @if [ -z "$$DFDISTRIB" ];then printf "DFDISTRIB not set, cannot determine target.\\n" >&2;exit 101;fi + removetar: @rm -vf dotfiles.tar.xz -- cgit v1.2.3