mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-14 11:45:55 +08:00
Add IsEnterpriseVersion flag
CURA-6569
This commit is contained in:
parent
7af5f132e0
commit
689562e61b
@ -9,7 +9,11 @@ DEFAULT_CURA_DISPLAY_NAME = "Ultimaker Cura"
|
|||||||
DEFAULT_CURA_VERSION = "master"
|
DEFAULT_CURA_VERSION = "master"
|
||||||
DEFAULT_CURA_BUILD_TYPE = ""
|
DEFAULT_CURA_BUILD_TYPE = ""
|
||||||
DEFAULT_CURA_DEBUG_MODE = False
|
DEFAULT_CURA_DEBUG_MODE = False
|
||||||
DEFAULT_CURA_SDK_VERSION = "7.0.0"
|
|
||||||
|
# Each release has a fixed SDK version coupled with it. It doesn't make sense to make it configurable because, for
|
||||||
|
# example Cura 3.2 with SDK version 6.1 will not work. So the SDK version is hard-coded here and left out of the
|
||||||
|
# CuraVersion.py.in template.
|
||||||
|
CuraSDKVersion = "7.0.0"
|
||||||
|
|
||||||
try:
|
try:
|
||||||
from cura.CuraVersion import CuraAppName # type: ignore
|
from cura.CuraVersion import CuraAppName # type: ignore
|
||||||
@ -32,6 +36,9 @@ try:
|
|||||||
except ImportError:
|
except ImportError:
|
||||||
CuraVersion = DEFAULT_CURA_VERSION # [CodeStyle: Reflecting imported value]
|
CuraVersion = DEFAULT_CURA_VERSION # [CodeStyle: Reflecting imported value]
|
||||||
|
|
||||||
|
# CURA-6569
|
||||||
|
# This string indicates what type of version it is. For example, "enterprise". By default it's empty which indicates
|
||||||
|
# a default/normal Cura build.
|
||||||
try:
|
try:
|
||||||
from cura.CuraVersion import CuraBuildType # type: ignore
|
from cura.CuraVersion import CuraBuildType # type: ignore
|
||||||
except ImportError:
|
except ImportError:
|
||||||
@ -42,7 +49,8 @@ try:
|
|||||||
except ImportError:
|
except ImportError:
|
||||||
CuraDebugMode = DEFAULT_CURA_DEBUG_MODE
|
CuraDebugMode = DEFAULT_CURA_DEBUG_MODE
|
||||||
|
|
||||||
# Each release has a fixed SDK version coupled with it. It doesn't make sense to make it configurable because, for
|
|
||||||
# example Cura 3.2 with SDK version 6.1 will not work. So the SDK version is hard-coded here and left out of the
|
# CURA-6569
|
||||||
# CuraVersion.py.in template.
|
# Various convenience flags indicating what kind of Cura build it is.
|
||||||
CuraSDKVersion = "7.0.0"
|
__ENTERPRISE_VERSION_TYPE = "enterprise"
|
||||||
|
IsEnterpriseVersion = CuraBuildType.lower() == __ENTERPRISE_VERSION_TYPE
|
||||||
|
Loading…
x
Reference in New Issue
Block a user