Unity Library Switcher is a Unity3d plugin for switching build targets and git branches without the burden of assets reimporting.
To install the plugin just copy UnityProject/Assets/UnityLibrarySwitcher folder to your project assets folder. Just don’t forget to add LibrarySwitcherCache folder to .gitignore file.
You have two actions:
- switch build target
- switch git branch
Both actions are available from the plugin window, which is accessible from Window/Library Switcher menu.
Library folder is cached for every (branch, target) pair. When you perform any action, the plugin will cache Library folder for current (branch, target) pair and then replace Library folder by the cached library of selected (branch, target) pair if it exists. To make things work faster plugin copies Library folder only in case you are moving to the (branch, target) pair that wasn’t cached before. If it was already cached, then plugin just moves directories around. All cached Library folders are stored in LibrarySwitcherCache folder in unity project root directory. (branch, target) pair’s Library folder is stored at LibrarySwitcherCache/branch/target.
- Due to the implementation details you should change build target or git branch only from the plugin window. Otherwise you will run into unnecessary imports.
- Branch switching only works with locally existing branches.
Pull requests, feature requests are warmly welcome!
Please, see Issues section.

