mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-25 23:53:56 -06:00
Use conf to get Cura version
This commit is contained in:
parent
1d8918f30d
commit
b7c1022ed1
1 changed files with 3 additions and 3 deletions
|
@ -261,7 +261,7 @@ class CuraConan(ConanFile):
|
||||||
with open(os.path.join(self.recipe_folder, "UltiMaker-Cura.spec.jinja"), "r") as f:
|
with open(os.path.join(self.recipe_folder, "UltiMaker-Cura.spec.jinja"), "r") as f:
|
||||||
pyinstaller = Template(f.read())
|
pyinstaller = Template(f.read())
|
||||||
|
|
||||||
version = self.conf_info.get("user.cura:version", default = self.version, check_type = str)
|
version = self.conf.get("user.cura:version", default = self.version, check_type = str)
|
||||||
cura_version = Version(version)
|
cura_version = Version(version)
|
||||||
|
|
||||||
with open(os.path.join(location, "UltiMaker-Cura.spec"), "w") as f:
|
with open(os.path.join(location, "UltiMaker-Cura.spec"), "w") as f:
|
||||||
|
@ -312,7 +312,7 @@ class CuraConan(ConanFile):
|
||||||
self.options["curaengine_grpc_definitions"].shared = True
|
self.options["curaengine_grpc_definitions"].shared = True
|
||||||
|
|
||||||
def validate(self):
|
def validate(self):
|
||||||
version = self.conf_info.get("user.cura:version", default = self.version, check_type = str)
|
version = self.conf.get("user.cura:version", default = self.version, check_type = str)
|
||||||
if version and Version(version) <= Version("4"):
|
if version and Version(version) <= Version("4"):
|
||||||
raise ConanInvalidConfiguration("Only versions 5+ are support")
|
raise ConanInvalidConfiguration("Only versions 5+ are support")
|
||||||
|
|
||||||
|
@ -446,7 +446,7 @@ class CuraConan(ConanFile):
|
||||||
copy(self, "*", uranium.libdirs[0], str(self._site_packages.joinpath("UM")), keep_path = True)
|
copy(self, "*", uranium.libdirs[0], str(self._site_packages.joinpath("UM")), keep_path = True)
|
||||||
|
|
||||||
# Generate the GitHub Action version info Environment
|
# Generate the GitHub Action version info Environment
|
||||||
version = self.conf_info.get("user.cura:version", default = self.version, check_type = str)
|
version = self.conf.get("user.cura:version", default = self.version, check_type = str)
|
||||||
cura_version = Version(version)
|
cura_version = Version(version)
|
||||||
env_prefix = "Env:" if self.settings.os == "Windows" else ""
|
env_prefix = "Env:" if self.settings.os == "Windows" else ""
|
||||||
activate_github_actions_version_env = Template(r"""echo "CURA_VERSION_MAJOR={{ cura_version_major }}" >> ${{ env_prefix }}GITHUB_ENV
|
activate_github_actions_version_env = Template(r"""echo "CURA_VERSION_MAJOR={{ cura_version_major }}" >> ${{ env_prefix }}GITHUB_ENV
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue