How to Git

I use git for almost all my work but I’m bit confused how editor source control works in UE4.
What I would like to know is if I use those checkout controls I’m guaranteed I can revive the project if something goes wrong?

Or is it better to just use the git ‘normal’ way on project folder?

UE Git plugin quite outdated, IIRC it was released with 4.7 and won’t updated since then. In my team we just go “normal” git way on folder.

Both the Git and Subversion plugins are wonky and in dire need of updates.

I just use the basic console commands in cmd line. Git Desktop is also a possibility but cmd line isn’t that hard because in git-hub when you create repositories it gives you the command line code describing exactly how to address and control things. Create one master backup local folder and then once you have two working folders git init one of them and leave the other alone just in case, stay away from the UE4 sc plugin for now.

I mostly use SourceTree as a git gui but need to use the terminal sometimes. I never use the in Editor plugin.

just a quick suggestion to use Perforce if you are part of a team…

Perforce locks binary assets (e.g level, any uasset) so avoids having to coordinate the “oh man you edited the level…so did I”

Also, the git repo gets really big really fast when making lots of changes to binary files. By default, it stores the entire change, not just a delta.

git-lfs can help with this - github supports it too now - so if you really must git, then git-lfs :slight_smile:

Again, for teams, Perforce is definitely worth your effort to switch…

I really wish Unreal would use line-based text formats for uassets. It would let you merge edits like that!

Can you give some insight on how lfs works/what the workflow is like?

If I install it will it seamlessly integrate into the existing git-hub projects I have or do I have to start over?

tempted to type git lfs install but don’t want to fubar anything.

Agreed. Unity has the text serialization mode which is great for using source control. Is there any chance we’d get something like that for UE4?

I am using git, as perforce is not worth it for a one person team.

The binary locking would be super nice in Git :open_mouth:

Git cannot do locking, because it doesn’t have a single master repository. You can make Git changes even when you’re not on a network. You can push your Git changes to whatever other Git repositories you choose to. Some of them may be configured as “git remotes” (which are like named shortcuts) and others may just be typed in at the time of push. Similarly, you can pull from wherever, whenever. This is the strength of Git, for the cases where it works, and also a weakness of Git, for cases it can’t deal with.

If you want to use Git the best, change binary formats to structured text, or write a custom diff/merge tool for the binary file formats for git to use…
If you absolutely need central locking, Perforce is going to work much better for you – but then you lose the things that Git is great at :frowning:

Text serialization by itself wouldn’t enable diff/merging. The way the data in blueprints is structured would need to be overhauled to make that possible, AFAIK, otherwise you just end up with a mangled blueprint: readable, but useless. So it’s not that simple.

I would agree with some of the others in this thread that using Git inside of UE4 is icky. I do use git, but when I’m done modifying stuff I jut go to the client and commit the changes. I use SourceTree with Microsoft Visual Team Services… MS is cool because you have unlimited private repos for under 5 developers.

teak