Video: how to compare branches with VSCode

Git Workflow for Cruise Deployments

1. Creating a New Cruise Branch

Before heading out on a cruise, create a new branch off master to track any changes made during the trip.

git checkout master  # Switch to the main branch
git pull origin master  # Ensure you have the latest changes
git checkout -b cruise-YYYY-MM  # Create a new branch (e.g., cruise-2025-03)
git push origin cruise-YYYY-MM  # Push the new branch to the remote repo

2. Making Changes During the Cruise

Work on this branch as needed. After making changes, commit them regularly:

git add .
git commit -m "Description of change"
git push origin cruise-YYYY-MM

3. Merging Back Into Master After the Cruise

Once the cruise is over and everything is tested, merge the branch back into master.

git checkout master  # Switch to master
git pull origin master  # Get the latest updates
git merge cruise-YYYY-MM  # Merge the cruise branch
git push origin master  # Push the updated master branch

If there are merge conflicts, resolve them manually, then continue the merge.


4. Tagging the Cruise for Future Reference

After merging, tag the repository so you can always refer back to this version:

git tag -a vYYYY-MM-cruise -m "Cruise YYYY-MM final version"
git push origin vYYYY-MM-cruise

Example: