Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Project size extremely large

Discussion in 'iOS and tvOS' started by Abdou23, Feb 29, 2016.

  1. Abdou23

    Abdou23

    Joined:
    May 2, 2014
    Posts:
    77
    I'm creating a game for mobile devices, the game is currently in prototype mode and only have exactly 4 sprites. The size of the project was 9MB, and I have the build platform set as IOS. When I attempt to upload to GitHub I found that the size changed to 1.4 GB!!! I started exploring the folder and deleted the "temp" folder and it got reduced to 411MB, still that is an extremely large size for this kind of project and the 4 sprites it includes.
    What is going on here? and how to get it back to it's original 9MB size?!!
     
  2. Abdou23

    Abdou23

    Joined:
    May 2, 2014
    Posts:
    77
    Has anyone ever encountered a problem like this?!!
     
  3. christophergoy

    christophergoy

    Unity Technologies

    Joined:
    Sep 16, 2015
    Posts:
    735
    Hi @Abdou23,
    If you exported your iOS project into your Unity project directory, then you will see this increase in size due to the Unity Engine library being copied into the Xcode project. It should not be a cause for alarm for you, unless you are reaching the limit of your github space. Let me know if you have any other questions.
    Thanks,
    Chris
     
  4. CPXTom

    CPXTom

    Joined:
    Apr 24, 2010
    Posts:
    113
    @Abdou23 You pretty much only want to version the "Assets" folder and the "ProjectSettings" folder. The other files shouldn't be versioned as they are meant to be recreated on each dev machine (eg temp files, xcode projects, etc..).

    These temp folders tend to be pretty large, but are not meant to be versioned, so your git repo should be much smaller :)
     
    Abdou23 likes this.
  5. Abdou23

    Abdou23

    Joined:
    May 2, 2014
    Posts:
    77
    Thank you for your response,
    1- If I exported the IOS project into a different directory, my original project will remain at its original size? (9MB)
    2- how much will be the size of the game on y phone after building it through Xcode?
     
  6. christophergoy

    christophergoy

    Unity Technologies

    Joined:
    Sep 16, 2015
    Posts:
    735
    Hey @Abdou23,
    Your unity project will likely only change size significantly when you add assets. If you make no changes, and export the iOS project to a different directory, it should not change size. @CPXTom also has a good point, that maybe setting up your .gitignore to exclude everything except the Assets and ProjectSettings folder can help you accomplish this. (I believe github has a Unity .gitignore template)

    I cannot give you an exact number, but it will be significantly smaller. If possible, you could to a test submit to the app store to get an estimate of the site of your app. This isn't very accurate, but it will give you an idea of how big your app will be when it comes time to download it from the app store. Apple is starting to require all app be submit with Bitcode enabled. This also makes the build size of your app significantly bigger than the actual download size of the app. Keep this in mind when submitting to the app store. I hope it will save you some stress ;)
    Cheers,
    Chris
     
  7. Abdou23

    Abdou23

    Joined:
    May 2, 2014
    Posts:
    77
    Thank you very much :)