Skip to content

Commit

Permalink
Update auto deploy branch from dev to main
Browse files Browse the repository at this point in the history
  • Loading branch information
Pil0tXia committed Apr 8, 2024
1 parent d296881 commit a238e04
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions deployment/auto-deploy-eventmesh-dashboard.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,13 @@ is_process_running() {

# Update the git repository
cd $REPO_PATH
git fetch origin dev
git fetch origin main
LOCAL=$(git rev-parse @)
REMOTE=$(git rev-parse origin/dev)
REMOTE=$(git rev-parse origin/main)

if [ $LOCAL != $REMOTE ]; then
# If the remote dev branch is newer than the local one, update the local dev branch code
git pull origin dev
# If the remote branch is newer than the local one, update the local branch code
git pull origin main

# Log the event
echo "$(date +"%Y-%m-%d %H:%M:%S") - change detected." >> $AUTO_DEPLOY_LOG
Expand All @@ -76,7 +76,7 @@ if [ $LOCAL != $REMOTE ]; then
# Log the event
echo "$(date +"%Y-%m-%d %H:%M:%S") - start new application." >> $AUTO_DEPLOY_LOG
else
# If there are no new changes in the remote dev branch
# If there are no new changes in the remote branch

# Log the event
echo "$(date +"%Y-%m-%d %H:%M:%S") - no change detected." >> $AUTO_DEPLOY_LOG
Expand Down

0 comments on commit a238e04

Please sign in to comment.