Remplacer 'git checkout' par 'git reset --hard' pour une mise à jour plus précise du dépôt.
All checks were successful
SSH Backend Deploy / ssh-deploy (push) Successful in 9s
All checks were successful
SSH Backend Deploy / ssh-deploy (push) Successful in 9s
This commit is contained in:
@@ -31,7 +31,7 @@ main() {
|
|||||||
|
|
||||||
log "Updating repository to match remote main branch..."
|
log "Updating repository to match remote main branch..."
|
||||||
git fetch origin
|
git fetch origin
|
||||||
git checkout -f origin/main
|
git reset --hard origin/main
|
||||||
if [ $? -ne 0 ]; then
|
if [ $? -ne 0 ]; then
|
||||||
log "Failed to update to the latest main branch."
|
log "Failed to update to the latest main branch."
|
||||||
exit 1
|
exit 1
|
||||||
|
|||||||
Reference in New Issue
Block a user