This site is currently in read-only mode during migration to a new platform.
You cannot post questions, answers or comments, as they would be lost during the migration otherwise.
+2 votes

Is there a way to get (with code) the Product Version configured inside the Export settings?

in Engine by (14 points)

2 Answers

0 votes

It looks like there is no script API to get this information, I thought it was saved in ProjectSettings regardless but it isn't.
I see it is saved in the export_presets.cfg.

If you want to access this from script you may ask for it in the issue tracker.

by (29,510 points)
+1 vote

You can edit the export_presets.cfg using the ConfigFile class.

Here's an example:

var export_config =
var export_config_path = "res://export_presets.cfg"
var config_error = export_config.load(export_config_path)
export_config.set_value("preset.0.options", "application/product_version", "dynamic product version")
by (20 points)

By default this file, export_presets.cfg, is not available on the exported version, you have to include then manualy on the resources tab of the export config

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.