locationPathName
Specifies the path for the application to be built.
Read time 1 minuteLast updated 6 days ago
Definition
- Type: Property
- Namespace: UnityEditor
- Assembly: UnityEditor.CoreModule
public string locationPathName { readonly get; set; }
Remarks
The value of determines both the location and the file name of the built application.
locationPathNameThis path can be either relative to the project directory or an absolute path.
Unity does not modify this path automatically, so it must include the correct file name and extension based on the target platform.
If the directory doesn't exist, Unity will create the directory automatically during the build process.
Guidelines:
-
The path must include your chosen file name. For example,for Android,
Builds/MyApp.apkfor Windows. Unity does not append extensions automatically.Builds/MyApp.exe -
For Android Package, use theextension and for Android App Bundle, use the
.apkextension..aab -
For Windows, use theextension.
.exe -
For Mac, use theextension.
.app -
If the path is relative (e.g.,), Unity will treat it as relative to the project root directory.
Builds/MyApp -
To place the build outside the project directory, specify an absolute path such as.
C:/MyBuilds/MyApp.exe
Don't use the following project directories for :
locationPathName-
Assets/
-
ProjectSettings/
-
Library/
-
Packages/
-
UserSettings/
Note: Paths pointing directly to the user desktop are not allowed.