- Home /
How to use GitHub properly for beginners an
Hi, I've been trying to work on a project with my friend in unity. So i searched up how to do so and was directed to source control and github. I've set it up but I believe there are a few problems. What i've done:
Downloaded github and cloned project to desktop
Set to Visible Meta Files and Force Text
Saved unity project into repo
When i save i make changes to files, i commit and sync my friend does the same thing
Problems - Regular problems with merging scenes. Also a lot of files are sent back and forth that are not directly made by me.
Please can you try to run me through what the steps we need to do to access the same files and what you do. Please explain as if you are telling a 5 year old because we don't understand most jargon and stuff
Thanks for all the help!
NB One of us uses VS on WIndows and the other uses Monodevelop in Mac
Hi, I figured out one of the problems. The gitignore file isnt working. It keeps sending all the files in the library and temp. How do i fix or where to i place it.
Answer by ZefanS · Feb 08, 2016 at 02:23 AM
Here's what I recommend based on my personal experience.
Make sure you set up your .gitignore correctly. It should be in the same directory as your .git file. The .gitignore here seems quite good and handles both VS and Monodevelop. Note that, as mentioned here,
If you already have a file checked in, and you want to ignore it, Git will not ignore the file if you add a rule later.
In other words, you may have to untrack a bunch of files that you want to ignore, or potentially just start a new repo from scratch.
As for the scene merging errors, it seems like the general consensus is that only one person should work on a scene at a time. If two people make changes there will be merge errors, but if only one person makes changes (per merge) the scenes can be merged automatically. Essentially this means you need to communicate clearly as to who does what, when.
It's not clear from your question whether you are or not, but I recommend learning how to use git from the command line. Here's a useful post for general git stuff.
Hope this helps!
Your answer
Follow this Question
Related Questions
SourceTree Hangs (not responding) with Unity Large Project 1 Answer
Super Ghouls 'n Ghosts style jumps & double jumps? 1 Answer
Why won't my power up work to buff my sword? 0 Answers
how to add a hole in the wall without effecting texture? 1 Answer
Not sure why I keep getting a Null Reference Exception? (Networking) 0 Answers