0
\$\begingroup\$

I'm just beginning to collaborate on a project with a second programmer. Unity Collab was causing issues with my teams unity causing 40 minute load times which was absolutely unmanageable.

Since then I've opted to use Bitbucket with LFS hosting and source tree for myself and artists.

I've been maintaining versions by myself but have not yet needed to roll back or make any significant changes to my files. Needless to say, my system is still working fine.

Now that I've got another programmer on my team to develop with, we've been getting him set up with bitbucket and the project. He however, has been completely unable to get the project to open as he's having 999+ errors of missing files from all my various assets and tools.


What Is There

In the project settings, I have version control set to "Text Only"

I have Unity Asset store tools such as:

  • Dialogue System for Unity
  • DoozyUI
  • Vegetation Studio Pro
  • and more...

My .gitattributes file looks like this:

## Unity ##

*.cs diff=csharp text
*.cginc text
*.shader text

#*.mat merge=unityyamlmerge eol=lf
#*.anim merge=unityyamlmerge eol=lf
#*.unity merge=unityyamlmerge eol=lf
#*.prefab merge=unityyamlmerge eol=lf
#*.physicsMaterial2D merge=unityyamlmerge eol=lf
#*.physicMaterial merge=unityyamlmerge eol=lf
#*.asset merge=unityyamlmerge eol=lf
#*.meta merge=unityyamlmerge eol=lf
#*.controller merge=unityyamlmerge eol=lf


## git-lfs ##


# Unity
*.mat filter=lfs diff=lfs merge=lfs -text
*.anim filter=lfs diff=lfs merge=lfs -text
*.unity filter=lfs diff=lfs merge=lfs -text
*.prefab filter=lfs diff=lfs merge=lfs -text
*.physicsMaterial2D filter=lfs diff=lfs merge=lfs -text
*.physicMaterial filter=lfs diff=lfs merge=lfs -text
*.asset filter=lfs diff=lfs merge=lfs -text
*.meta filter=lfs diff=lfs merge=lfs -text
*.controller filter=lfs diff=lfs merge=lfs -text

#Image
*.jpg filter=lfs diff=lfs merge=lfs -text
*.jpeg filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.gif filter=lfs diff=lfs merge=lfs -text
*.psd filter=lfs diff=lfs merge=lfs -text
*.ai filter=lfs diff=lfs merge=lfs -text
*.tif filter=lfs diff=lfs merge=lfs -text

#Audio
*.mp3 filter=lfs diff=lfs merge=lfs -text
*.wav filter=lfs diff=lfs merge=lfs -text
*.ogg filter=lfs diff=lfs merge=lfs -text

#Video
*.mp4 filter=lfs diff=lfs merge=lfs -text
*.mov filter=lfs diff=lfs merge=lfs -text

#3D Object
*.FBX filter=lfs diff=lfs merge=lfs -text
*.fbx filter=lfs diff=lfs merge=lfs -text
*.blend filter=lfs diff=lfs merge=lfs -text
*.obj filter=lfs diff=lfs merge=lfs -text

#ETC
*.a filter=lfs diff=lfs merge=lfs -text
*.exr filter=lfs diff=lfs merge=lfs -text
*.tga filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.dll filter=lfs diff=lfs merge=lfs -text
*.unitypackage filter=lfs diff=lfs merge=lfs -text
*.aif filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.rns filter=lfs diff=lfs merge=lfs -text
*.reason filter=lfs diff=lfs merge=lfs -text
*.lxo filter=lfs diff=lfs merge=lfs -text
*.so filter=lfs diff=lfs merge=lfs -text

My .gitignore

# This .gitignore file should be placed at the root of your Unity project directory
#
# Get latest from https://github.com/github/gitignore/blob/master/Unity.gitignore
#
/[Ll]ibrary/
/[Tt]emp/
/[Oo]bj/
/[Bb]uild/
/[Bb]uilds/
/[Ll]ogs/
/[Uu]ser[Ss]ettings/
/UMotionData/

# MemoryCaptures can get excessive in size.
# They also could contain extremely sensitive data
/[Mm]emoryCaptures/

# Asset meta data should only be ignored when the corresponding asset is also ignored
!/[Aa]ssets/**/*.meta

# Uncomment this line if you wish to ignore the asset store tools plugin
# /[Aa]ssets/AssetStoreTools*

# Autogenerated Jetbrains Rider plugin
/[Aa]ssets/Plugins/Editor/JetBrains*

# Visual Studio cache directory
.vs/

# Gradle cache directory
.gradle/

# Autogenerated VS/MD/Consulo solution and project files
ExportedObj/
.consulo/
*.csproj
*.unityproj
*.sln
*.suo
*.tmp
*.user
*.userprefs
*.pidb
*.booproj
*.svd
*.pdb
*.mdb
*.opendb
*.VC.db

# Unity3D generated meta files
*.pidb.meta
*.pdb.meta
*.mdb.meta

# Unity3D generated file on crash reports
sysinfo.txt

# Builds
*.apk
*.aab
*.unitypackage

# Crashlytics generated file
crashlytics-build.properties

# Packed Addressables
/[Aa]ssets/[Aa]ddressable[Aa]ssets[Dd]ata/*/*.bin*

# Temporary auto-generated Android Assets
/[Aa]ssets/[Ss]treamingAssets/aa.meta
/[Aa]ssets/[Ss]treamingAssets/aa/*

At one point my sourcetree was notifying me that there were major files that were staged but not marked as an LFS file. Because of this, I commented out those unityamlmerge lines and added LFS lines for the same files.


Theories

  1. My collaborator doesn't have all the asset store tools and thus cannot use them.
  2. My .gitattribute file is incomplete/incorrect.
  3. The asset store files may use their own proprietary filetypes that are not properly included in the .gitattributes file.
  4. Something I have yet to even comprehend.

Thanks for any help and feedback. I really need to get this team member set up and rolling.

\$\endgroup\$
5
  • \$\begingroup\$ 5. you guys messed up your lfs installation(s) \$\endgroup\$
    – dot_Sp0T
    Sep 10 '20 at 21:49
  • \$\begingroup\$ @dot_Sp0T How would we go about making sure that they're installed properly on both sides? Do we need to assure the version number? Are there other things that need to be considered? \$\endgroup\$ Sep 10 '20 at 22:30
  • \$\begingroup\$ What does your .gitignore file look like? Also I would not recommend using LFS as it causes more problems than it solves. \$\endgroup\$
    – andrew zuo
    Sep 11 '20 at 5:14
  • \$\begingroup\$ @GaianSwineHelmers the few times i needed to use gitlfs the best way to setup was that one person set it up on each computer. I understand that's not necessarily what you're looking for, but it provided the best results each time. \$\endgroup\$
    – dot_Sp0T
    Sep 11 '20 at 6:27
  • \$\begingroup\$ @andrew-zuo I'm not sure how we'd otherwise share almost 10 gigs of game assets, tools, and files in a well organized way. I could imagine Dropbox possibly being a solution for that... but would not have any idea of how to begin implementing that. I've added the gitignore to the post. dot_Sp0T: That definitely makes sense. Consistency is always a good rule. Have either of you encountered conflicts with not having asset "seats" and not being able to use asset store files while collaborating on a project? I don't know how Unity or Bitbucket would be able to enforce that when pushing files. \$\endgroup\$ Sep 11 '20 at 19:17

You must log in to answer this question.

Browse other questions tagged .