* cde53d9 (origin/main, main) Merge branch 'develop'
|\
| * 7d94faa (HEAD -> develop) Merge branch 'feature/road-view' into develop
After merging the feature/road-view branch into the develop branch and subsequently merging develop into main, the main branch is now ahead of develop by one commit. In this situation, if I need to create new feature branches from the develop branch and continue working, should I merge main back into develop, aligning the versions, before proceeding with the work?
No. Don't worry about the extra merge commit on
main. The states ofdevelopandmainare the same; only a new merge-commit is missing ondevelop. So, you can mergemainback intodevelop, but you don't have to. However, if you merge ahotfixintomainthat isn't yet ondevelop, then you must merge thehotfix(or better yetmain) back down todevelopas well.That being said, note that standard Git Flow doesn't have a scenario where
developis directly merged intomain. Instead an in-betweenreleasebranch would be used. If you find yourself not needing areleasebranch, then you may not need the complexity of Git Flow. If this is your case, you could consider renamingdeveloptomainand tag your releases so you know when you deployed. This workflow is simpler, and is commonly called "Feature Branch workflow", and also "GitHub Flow".