I couldn't find any similar questions for this precise requirement.
Assume I have a feature and a main branch.
We have some new commits in the main branch after creating the feature branch.
What I want to do is merge into the main at the precise commit in which feature branch was created, as shown in the image below. In other words, feature commits come before main commits.

[![enter image description here](https://i.stack.imgur.com/ufCpn.png)](https://i.stack.imgur.com/ufCpn.png)