From 1d1dd3575bd2779538aac36817da19a8ad8ef681 Mon Sep 17 00:00:00 2001
From: Jon Azpiazu <jon.azpiazu@tecnalia.com>
Date: Tue, 3 Dec 2019 13:20:05 +0100
Subject: [PATCH] Failsafe script

---
 scripts/asciidoctor_syntax_check.bash | 1 +
 1 file changed, 1 insertion(+)

diff --git a/scripts/asciidoctor_syntax_check.bash b/scripts/asciidoctor_syntax_check.bash
index 1aaa244..fb66a87 100644
--- a/scripts/asciidoctor_syntax_check.bash
+++ b/scripts/asciidoctor_syntax_check.bash
@@ -10,6 +10,7 @@ if [ -z "$1" ] ; then
     exit 1
 fi
 
+touch output.log # avoid failing if no adoc files exist
 while IFS= read -r -d '' filename; do
   asciidoctor "$filename" 2>&1 | tee -a output.log
 done < <(find "$1" -name '*.adoc' -type f -print0)
-- 
GitLab