I agree working with git has it’s downsides atm compared to good old svn. It makes more sense when you realise you have three copies:
- teamserver (mainline/branch)
- local copy
- local (working directory)
When you change things, you save in “local (working dir)”. When you commit, you commit to your local copy and optionally (default = yes) to the teamserver. When a colleague has committed stuff to the teamserver, I think you should commit your changes first (to local copy only, so toggle the “commit to remote server” boolean), update, then push.
Several things make no sense though:
- when checking history, I think the local copy history is shown, causing, as you mentioned, the impression that your colleague’s changes are actually yours
- commits to local copy also show up in the teamserver history in the Mendix Cloud portal, but maybe I misunderstand something here
- Studio Pro sometimes wants you to update before committing, while there are no changes on the teamserver
- Studio Pro considers your working directory changed while you’ve undone your changes, which is annoying
- When you update, you still need to commit the received changes to your local copy, which is confusing, especially when you combine that with your own additional changes and commit to the remote server
Also Studio Pro could make more use of git features, like committing a subset of available changes to the teamserver. It does already cause less conflicts, but that may also be a change by Mendix where svn would also benefit, but I have no Mx9 svn projects, only git, so I can’t really compare.
Still, I’d recommend starting new projects with git version control. You’ll have to migrate from svn to git sooner or later. And the way git is implemented may be confusing sometimes, but I haven’t had serious problems or issues.
I agree; working with Git in Mendix is a struggle right now. I hope this will be improved since we HAVE to use Git in Mx10.I agree; working with Git in Mendix is a struggle right now. I hope this will be improved since we HAVE to use Git in Mx10.
Working with Git is a nightmare. One app, I can’t convert (unknown reasons, had to send to R&D). another app, I converted and the time it takes to push changes or publish has extended beyond 30 minutes. hopefully they clean this up and put out a hotfix as it makes it really hard to work with source control properly.
Just want to add my frustration here. Working with git is still a nightmare in 9.24.27. I hope it will be tremendously better in Mendix 10.