diff options
author | Charadon <dev@iotib.net> | 2022-09-30 12:11:26 -0400 |
---|---|---|
committer | Charadon <dev@iotib.net> | 2022-09-30 12:11:26 -0400 |
commit | 545ad2ba2842a8b054e8fdd218e95c5424955729 (patch) | |
tree | a663b0be3d0a0451cc659c857acc427faa6ce639 | |
parent | 268b2dd09c15830b97d1138e6c42e44f3e376e00 (diff) | |
download | dscip-545ad2ba2842a8b054e8fdd218e95c5424955729.tar.gz |
setup.sh: Fixed issue where git clone fails with empty DSCIP_VERSION 0.9.4
-rwxr-xr-x | setup.sh | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/setup.sh b/setup.sh index 4c3f75c..391d828 100755 --- a/setup.sh +++ b/setup.sh @@ -107,12 +107,13 @@ install_dscip() { install -m755 "$DSCIP_PATH"/config.sh "$PROJECT_LOCATION"/config.sh install_templates || cp "$DSCIP_PATH"/*.sh . else # If not, clone it from upstream. - if [ -z "$DSCIP_VERSION" ]; + if [ ! "$DSCIP_VERSION" = "" ]; then # Check if using a release setup.sh, if not, clone from master. git clone "https://opencode.net/charadon/dscip" --depth 1 --branch "$DSCIP_VERSION" "$PROJECT_LOCATION" else git clone "https://opencode.net/charadon/dscip" "$PROJECT_LOCATION" fi + rm "$PROJECT_LOCATION"/setup.sh install_templates || echo "Skipping templates as no Template Directory was set..." fi # Modifying config.sh with variables obtained from setup.sh |