From 152a9ea1ee5f12cae69448a4971adaa1b2fbcc17 Mon Sep 17 00:00:00 2001 From: Sebastiano Tronto Date: Mon, 26 Sep 2022 17:32:39 +0200 Subject: Improved rsync name resolution --- Makefile | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 4352b9f..ea13048 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,6 @@ DEST="tronto.net:/var/www/htdocs/sebastiano.tronto.net" DESTGEMINI="tronto.net:/var/gemini" +RSYNC=$$( (command -V rsync 2>&1 > /dev/null && echo rsync) || echo openrsync) all: clean ./build.sh @@ -11,11 +12,9 @@ clean: deploy: syncgemini synchttp syncgemini: - rsync -rv --delete --rsync-path=openrsync gemini/ ${DESTGEMINI} || \ - openrsync -rv --delete --rsync-path=openrsync gemini/ ${DESTGEMINI} + ${RSYNC} -rv --delete --rsync-path=openrsync gemini/ ${DESTGEMINI} synchttp: - rsync -rv --delete --rsync-path=openrsync http/ ${DEST} || \ - openrsync -rv --delete --rsync-path=openrsync http/ ${DEST} + ${RSYNC} -rv --delete --rsync-path=openrsync http/ ${DEST} .PHONY: all clean deploy syncgemini synchttp -- cgit v1.3