Skip to content

Instantly share code, notes, and snippets.

@vwbusguy
Created March 17, 2026 22:53
Show Gist options
  • Select an option

  • Save vwbusguy/72c7c66360b7a2efd14b2f3d68c61872 to your computer and use it in GitHub Desktop.

Select an option

Save vwbusguy/72c7c66360b7a2efd14b2f3d68c61872 to your computer and use it in GitHub Desktop.
Keep your main and develop branches in sync
#!/bin/bash
git checkout main ; git pull --ff ; git checkout develop && git pull --ff || git checkout -b develop ; git merge main ; git push
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment