forked from ungleich-public/cdist
ignore trailing slashes for comparison of source
Signed-off-by: Steven Armstrong <steven@icarus.ethz.ch>
This commit is contained in:
parent
301b4e18ff
commit
5ec617fa3e
1 changed files with 2 additions and 1 deletions
|
@ -35,7 +35,8 @@ case "$type" in
|
|||
cd "$destination_dir"
|
||||
source_is=$(ls -l "$destination" | sed 's/.*-> //g')
|
||||
if [ -h "$destination" ]; then
|
||||
if [ "$source_is" = "$source" ]; then
|
||||
# ignore trailing slashes for comparison
|
||||
if [ "${source_is%/}" = "${source%/}" ]; then
|
||||
echo present
|
||||
else
|
||||
echo wrongsource
|
||||
|
|
Loading…
Reference in a new issue