Browse Source

Fix script to script call using dirname "$0".

Script is run with different workdir.
Herby Vojčík 4 years ago
parent
commit
8a67341d8f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      check-vcs-changes.sh

+ 1 - 1
check-vcs-changes.sh

@@ -5,7 +5,7 @@ if [ -n "$PLUGIN_IGNORE" -a \( -n "$PLUGIN_POSITIVE" -o -n "$PLUGIN_NEGATIVE" \)
   set "$PLUGIN_IGNORE" "$PLUGIN_POSITIVE" "$PLUGIN_NEGATIVE"
 fi
 
-if git diff --name-only "$DRONE_COMMIT_AFTER" "$DRONE_COMMIT_BEFORE" | ./check-some-are-unignored.sh "$1"; then
+if git diff --name-only "$DRONE_COMMIT_AFTER" "$DRONE_COMMIT_BEFORE" | `dirname "$0"`/check-some-are-unignored.sh "$1"; then
   if [ -n "$2" ]; then touch "$2"; fi
 else
   if [ -n "$3" ]; then touch "$3"; fi