From fed91f7b1d2e560b6a6d7be30aa500cbe2ae5784 Mon Sep 17 00:00:00 2001
From: Christoph Lehmann <christoph.lehmann@ufz.de>
Date: Fri, 3 Jun 2016 13:24:09 +0200
Subject: [PATCH] [scr/doc] fix shell command related errors

---
 scripts/doc/get-project-params.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/scripts/doc/get-project-params.sh b/scripts/doc/get-project-params.sh
index 754b21adc92..09db7ccc768 100755
--- a/scripts/doc/get-project-params.sh
+++ b/scripts/doc/get-project-params.sh
@@ -10,7 +10,7 @@ if [ $# -ne 1 ]; then
     exit 1
 fi
 
-srcdir="`readlink -f "$1"`"
+srcdir="`realpath "$1"`"
 
 #color="--color=always"
 color=""
@@ -23,7 +23,7 @@ cat <<"EOF" \
     --exclude-dir 'Tests' \
     --exclude 'ConfigTree*.*' \
     -f - -r -n -o $color \
-| cut -c $((`expr length "$srcdir"` + 2))-
+| cut -c $((${#srcdir} + 2))-
 ^\s*//! \\ogs_file_\(param\|attr\){[A-Za-z_0-9]\+}\( \\todo .*\)\?$
 ^\s*//! \\ogs_file_special$
 ^\s*//! \\ogs_file_\(param\|attr\)_special{[A-Za-z_0-9]\+}\( \\todo .*\)\?$
-- 
GitLab