Jump to content
Sign in to follow this  
SDSChad

GitSync - Replicated changesets merge issue

Recommended Posts

Hello, I think I did something wrong, but I'm not sure exactly what yet. I recently did a git sync from Plastic and it told me that I needed to merge with the changes from Git, even though I had not made any direct changes to the git repo (all changes were performed through Plastic). Here are the steps that I followed:

Machine A:

1. Created initial checkin along with a handful of other ones to main.

2. Synchronized all changes to my gitsync git repo.

Machine B:

3. Made a few more checkins to main through Plastic. 

4. Synchronized all changes to my gitsync git repro.

After step 4, Plastic told me that my git repo had changed and that I need to merge. My branch explorer is attached and the red lines show changesets that are identical between the two (the bottom track was newly added by the git sync operation mentioned in step 4), but are somehow now needing to be merged. 

My question is if this is expected behavior? Should I just merge those identical changesets in, or did I do something improperly when switching between machines? Any help would be appreciated!

Thank you,

Chad

 

gitsync_issue.png

Share this post


Link to post
Share on other sites

Hi @SDSChad,

When you run an initial Gitsync operation, one the repos involved always need to be empty.

The problem is:

Quote

 

Machine B:

3. Made a few more checkins to main through Plastic. 

4. Synchronized all changes to my gitsync git repro.

 

In the Machine B, you don't have any previous GitSync mappings. This machine is not aware of the previous GitSync performed in Machine A. When you sync the git repo, the commits are duplicated into your Plastic repo (at the end of the day breaking the repo).  Machine B doesn't know that there was a previous sync.

You will need to manually remove the duplicated changesets.

Summary:

- Always perform the GitSync from the same machine.

- If you want also do it from a different machine, you will need to use a clean new repo for the initial sync. These ways, the mappings will be also generated in the new machine (and not changesets will be duplicated).

Regards,

Carlos.

 

 

Share this post


Link to post
Share on other sites

Ah, I see now. I deleted the duplicated changesets and performed the gitsync from Machine A and everything is working as expected. Thank you for the information! 

On a related note, my primary reason for using GitSync is to interface with Unity Cloud Build. Is there a preferred way to lobby Unity for Plastic support? 

Best,

Chad

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...