How to keep you deployment detail when merging

Good morning all,

I am having a difficult time with merging in git.

I have two branches in my project:

Master - This is the production branch and deploys to production server.

Development Branch - This branch needs to deploy to a different development server.

Now when I merge from one to the other the .idea/deployment.xml gets over written.

I have tried several things.

  1. I tried removing this entire folder from GIT via
    #git rm -r --cache .idea
    this was done in both branches.
  2. I tried using:
    #git config --global merge.ours.driver true
    and then adding
    /.idea/deployment.xml   merge=ours
  3. I tried adding deployment.xml to the. gitignore file
  4. Several combinations of all three

However, when I merge back and forth the deployment XML seems to be intermittently overwritten. Can someone please tell me how I can accomplish what I am looking to do. Any help would be greatly appreciated.

0

请先登录再写评论。