This repository was archived by the owner on May 19, 2021. It is now read-only.
Allowing override of Project Version with a text file#57
Merged
unitycoder merged 1 commit intounitycoder:masterfrom Apr 6, 2018
Merged
Allowing override of Project Version with a text file#57unitycoder merged 1 commit intounitycoder:masterfrom
unitycoder merged 1 commit intounitycoder:masterfrom
Conversation
…verride.txt file in the root directory
Owner
|
thanks looks good, ill merge it soon! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This commit adds support for overriding the Unity Version that will be used for a project by reading from a file called "ProjectVersionOverride.txt" in the root directory of a project.
My use case for this feature is having multiple copies of the same project which has the Assets folder and ProjectSettings folder sym-linked to a shared directory. When pulling from Git, it will update the Assets and ProjectSettings automatically for multiple Unity Project folders.
I do it this way because I need to have a separate version of Unity being used for different platforms - e.g. Console builds require a specific version / patch version of Unity, but the PC version needs a separate version. By reading from the file in ProjectSettings, it will be copied across to all my shared projects via the symlinks. However, having this special override file outside of the ProjectSettings directory (in the root of the project) will allow me to use the UnityLauncher and keep track of the exact version needed for each platform of a project even if the data in ProjectSettings is different from this.
If there is no file named "ProjectVersionOverride.txt" in the root of the project, then it will check the Unity project version as normal without using this extra check.