Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
6
Question by Wekthor · Sep 25, 2015 at 01:23 PM · unity 5assetdatabasegitgithubmetadata

Unity Git - Ignore Library

Hi, we have been trying to setup Git with Unity past two days on our project between Mac and Pc. We got it kinda working, but we still have issues with metadata and conflicts in Library/AssetDatabase3. We got whole Library folder in .gitignore file but for some reason it seems some files in it are not ignored. We will also get during commits huge list of metadata instead of only seeing changes on files which actualy changed, there will be list of hundreds of metadata. Again coming from Library.

Any idea why Library folder doesnt get full ignored with ignore file ? The issue with conflicts seems to be coming from assetDabase file. Any suggestions for good workflow between Mac and Pc ?

Thanks

.gitignore file

 #For Mac developers
 # Unity generated #
 # =============== #
 Temp/
 obj/
 Build
 Library/
  
 
     # ===================================== #
     # Visual Studio / MonoDevelop generated #
     # ===================================== #
     ExportedObj/
     *.svd
     *.userprefs
     *.csproj
     *.pidb
     *.suo
     *.sln
     *.user
     *.unityproj
     *.booproj
     *.orig
     *.app
     *.exe
     *.*_data
     
     Build/iOS
     Build/android
     
     *.[od]
     
     # ============ #
     # OS generated #
     # ============ #
     .DS_Store
     .DS_Store?
     ._*
     .Spotlight-V100
     .Trashes
     Icon?
     ehthumbs.db
     Thumbs.db


Comment
Add comment · Show 3
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Dave-Carlile · Sep 25, 2015 at 01:30 PM 1
Share

$$anonymous$$ind of hard to tell without seeing your gitignore. Ignoring Library does work...

I started out with this: https://github.com/github/gitignore/blob/master/Unity.gitignore

avatar image Wekthor Dave-Carlile · Sep 25, 2015 at 02:56 PM 0
Share

sorry, added

avatar image Powderek · May 13, 2016 at 02:42 PM 0
Share

Have you found the solution?

2 Replies

· Add your reply
  • Sort: 
avatar image
7

Answer by sys12 · Sep 25, 2015 at 03:20 PM

try:

 git rm -r --cached .
 git add .
 git commit -m "blablabla"

,if you think your .gitignore file is good and not working.

http://stackoverflow.com/questions/11451535/gitignore-not-working

Comment
Add comment · Show 2 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Wekthor · Sep 25, 2015 at 04:33 PM 0
Share

hi, this unfortunately didnt work for me, actualy it messed up whole Unity ( crashing on every start up ) and i had to roll back to old commit.

avatar image Dave-Carlile · Sep 25, 2015 at 04:43 PM 0
Share

One of the answers at that link mention that leading or trailing spaces or tabs cause problems. It might just be the formatting here, but there is at least one space before every line on OP's file. $$anonymous$$ight want to verify that that isn't the case in your actual file.

avatar image
0

Answer by 3DDean · Sep 25, 2015 at 03:15 PM

The meta files are not in the library. They reside in the Assets folder and if you have just setup git to Unity the meta files with be tracked. You should just have to add them all to the file and add some comment to them. Then they will go away. At least that's what happened when i added git a 2 days ago. the .meta folder will be created by unity every time you create a new file. Also got to edit > project settings > editor > version control and set it to visible meta files. They are marked as hidden otherwise. So you should be able to see them if you have a view hidden files on in your OS.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

36 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

SourceTree Hangs (not responding) with Unity Large Project 1 Answer

How to share a unity project between Mac & windows on GitHub 1 Answer

.gitignore not ignoring Library. What's the correct way to do it? 1 Answer

Ignoring Library/metadata with Unity4/Github/Win8x64 1 Answer

Make git ignore *_Data/ build output 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges