Refactor deployment scripts to use git fetch and reset for pulling latest changes. Update deploy-production.sh and deploy-test.sh to ensure a clean state before deployment. Modify code-analysis.yml to reflect these changes in deployment commands.
This commit is contained in:
@@ -208,7 +208,9 @@ git clean -fd \
|
||||
|
||||
# Pull latest changes
|
||||
echo " Pulling latest changes..."
|
||||
if ! git pull --ff-only; then
|
||||
git fetch origin main
|
||||
git checkout -B main origin/main
|
||||
if ! git reset --hard origin/main; then
|
||||
echo "ERROR: git pull fehlgeschlagen."
|
||||
echo ""
|
||||
echo "Häufige Ursache: SSH-Key für den aktuellen User fehlt."
|
||||
|
||||
Reference in New Issue
Block a user