From 912ce78a1f0a7f6c0e0a87c0b633a8089cbbd788 Mon Sep 17 00:00:00 2001 From: tv Date: Thu, 27 Jul 2017 20:32:03 +0200 Subject: create target path when using force --- lib/populate.jq | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/populate.jq b/lib/populate.jq index c51e44e..911e956 100644 --- a/lib/populate.jq +++ b/lib/populate.jq @@ -36,6 +36,11 @@ def checktarget_script: @sh "fi"; +def forcetarget_script: + @sh "mkdir -vp \($target.path)", + @sh "touch \($target.path)/.populate"; + + def git_script: @sh "fetch_git(){(", #@sh " export SSL_CERT_FILE=/etc/ssl/certs/ca-certificates.crt", @@ -118,7 +123,7 @@ def ssh_target: [ - (if $use_force then null else checktarget_script end), + (if $use_force then forcetarget_script else checktarget_script end), git_script ] | (if $is_local then . else [ssh_target] end), -- cgit v1.2.3