Created
August 2, 2018 12:29
-
-
Save eminetto/8819789aac282320fb1396a201a40969 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash -e | |
SHOULD_BUILD=0 | |
shouldIBuild() { | |
if [[ "${DRONE_DEPLOY_TO}" ]]; then | |
SHOULD_BUILD=1 | |
else | |
. scripts/detectChangedFolders.sh | |
detect_changed_folders | |
toW=($(echo "$watch" | tr ' ' '\n')) | |
changed=($(echo "$changed_components")) | |
for i in "${toW[@]}" | |
do | |
for j in "${changed[@]}" | |
do | |
if [[ $i = $j ]]; then | |
SHOULD_BUILD=1 | |
fi | |
done | |
done | |
fi | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment