You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +00:00
Add a "version" project setting and use it in new export presets
This makes it easy to retrieve the project version at runtime for display purposes, while simplifying the export preset configuration. You can now leave the version empty unless you need to override it on a per-preset basis. Since export presets save the values of default values to the `export_presets.cfg` file, this change only affects export presets created after this commit was merged.
This commit is contained in:
@@ -177,7 +177,7 @@ void EditorExportPlatformIOS::get_export_options(List<ExportOption> *r_options)
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/bundle_identifier", PROPERTY_HINT_PLACEHOLDER_TEXT, "com.example.game"), "", false, true));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/signature"), ""));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/short_version"), "1.0"));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/version"), "1.0"));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/version", PROPERTY_HINT_PLACEHOLDER_TEXT, "Leave empty to use project version"), ""));
|
||||
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::INT, "application/icon_interpolation", PROPERTY_HINT_ENUM, "Nearest neighbor,Bilinear,Cubic,Trilinear,Lanczos"), 4));
|
||||
r_options->push_back(ExportOption(PropertyInfo(Variant::INT, "application/launch_screens_interpolation", PROPERTY_HINT_ENUM, "Nearest neighbor,Bilinear,Cubic,Trilinear,Lanczos"), 4));
|
||||
@@ -284,7 +284,7 @@ void EditorExportPlatformIOS::_fix_config_file(const Ref<EditorExportPreset> &p_
|
||||
} else if (lines[i].find("$short_version") != -1) {
|
||||
strnew += lines[i].replace("$short_version", p_preset->get("application/short_version")) + "\n";
|
||||
} else if (lines[i].find("$version") != -1) {
|
||||
strnew += lines[i].replace("$version", p_preset->get("application/version")) + "\n";
|
||||
strnew += lines[i].replace("$version", p_preset->get_version("application/version")) + "\n";
|
||||
} else if (lines[i].find("$signature") != -1) {
|
||||
strnew += lines[i].replace("$signature", p_preset->get("application/signature")) + "\n";
|
||||
} else if (lines[i].find("$team_id") != -1) {
|
||||
|
||||
Reference in New Issue
Block a user