PyAPI: Skip user scripts w/ factory-startup
Adds bpy.app.factory_startup, used to check if user scripts should be loaded.
This commit is contained in:
@@ -89,6 +89,7 @@ static PyStructSequence_Field app_info_fields[] = {
|
||||
{(char *)"version_cycle", (char *)"The release status of this build alpha/beta/rc/release"},
|
||||
{(char *)"binary_path", (char *)"The location of blenders executable, useful for utilities that spawn new instances"},
|
||||
{(char *)"background", (char *)"Boolean, True when blender is running without a user interface (started with -b)"},
|
||||
{(char *)"factory_startup", (char *)"Boolean, True when blender is running with --factory-startup)"},
|
||||
|
||||
/* buildinfo */
|
||||
{(char *)"build_date", (char *)"The date this blender instance was built"},
|
||||
@@ -165,6 +166,7 @@ static PyObject *make_app_info(void)
|
||||
SetStrItem(STRINGIFY(BLENDER_VERSION_CYCLE));
|
||||
SetStrItem(BKE_appdir_program_path());
|
||||
SetObjItem(PyBool_FromLong(G.background));
|
||||
SetObjItem(PyBool_FromLong(G.factory_startup));
|
||||
|
||||
/* build info, use bytes since we can't assume _any_ encoding:
|
||||
* see patch [#30154] for issue */
|
||||
|
Reference in New Issue
Block a user