fix: always set the git rev env var when building an app via git:sync

Closes #6827
This commit is contained in:
Jose Diaz-Gonzalez
2024-09-28 23:47:48 -04:00
parent b9ebf2bcca
commit 4ec6fa3eb0
2 changed files with 8 additions and 2 deletions

View File

@@ -235,10 +235,11 @@ cmd-git-sync() {
if [[ "$SHOULD_BUILD" == "true" ]]; then
if [[ -n "$GIT_REF" ]]; then
GIT_REF="$(fn-git-cmd "$APP_ROOT" rev-parse "$GIT_REF")"
plugn trigger receive-app "$APP" "$GIT_REF"
else
plugn trigger receive-app "$APP"
GIT_REF="$UPDATED_REF"
fi
plugn trigger receive-app "$APP" "$GIT_REF"
plugn trigger deploy-source-set "$APP" "git-sync" "${GIT_REMOTE}#${GIT_REF}"
fi
}