[TUTORIAL] How to use Setup.bat and how to reduce download size

Hi, just an update with my finding on current master with upcoming UE 4.19.

-exclude=Dingo does nothing for me, nor -exclude=Switch, and -exclude=Mac -exclude=Linux are already the defaults, so here is the command I am using:



Setup.bat -exclude=WinRT -exclude=Linux32 -exclude=osx32 -exclude=Android -exclude=HTML5 -exclude=TVOS -exclude=IOS -exclude=GoogleVR -exclude=GoogleTest -exclude=LeapMotion


This by itself reduce the download of more than 1.6GB :slight_smile:

Using the above “.gitdepsignore” you can skip some 1.6GB more.

So, coming from:



Setup.bat
Checking dependencies (excluding Mac, Linux)...
Updating dependencies:   0% (1/31957), 1.9/**5559.8** MiB


Combining those two get you to:



Setup.bat -exclude=WinRT -exclude=Linux32 -exclude=osx32 -exclude=Android -exclude=HTML5 -exclude=TVOS -exclude=IOS -exclude=GoogleVR -exclude=GoogleTest -exclude=LeapMotion
Checking dependencies (excluding Mac, Linux, WinRT, Linux32, osx32, Android, HTML5, TVOS, IOS, GoogleVR, GoogleTest, LeapMotion)...
Updating dependencies:   0% (1/19936), 1.9/**2216.9** MiB


3 Likes

This is super useful!
Is there maybe a list of exclude/include options for current 5.0/5.1 branch?

2 Likes

Noob question, what’s the GitDependencies program mentioned here?

:raised_back_of_hand: The way to save you disk storage.

:white_check_mark: Try to read Commit.gitdeps.xml file.
This file is about what dependencies you will download.And exclude option string is related to File Name in it.

:man_technologist: The code is in here

These options work well in UE5.31

–exclude=osx64 --exclude=osx32 --exclude=TVOS --exclude=Mac --exclude=mac-arm64 --exclude=WinRT --exclude=Linux --exclude=Linux32 --exclude=Linux64 --exclude=Unix --exclude=OpenVR --exclude=GoogleOboe --exclude=GooglePlay --exclude=GoogleGameSDK

–exclude=Documentation --exclude=Samples --exclude=Templates

You can also add .gitdepsignore to root folder to precise deps control.

Engine/Plugins/Runtime/OpenXR

:white_check_mark: If you don’t need to use git clean -fdx command,delete .git/ue-gitdeps folder to remove download cache file or use –no-cache option to avoid cache.
:man_technologist: The code is in this commit.

1 Like