diff options
author | Jaime van Kessel <nallath@gmail.com> | 2019-07-23 12:23:42 +0300 |
---|---|---|
committer | Jaime van Kessel <nallath@gmail.com> | 2019-07-23 12:23:42 +0300 |
commit | 57eb47e26700d28781750a46750df71758a690fc (patch) | |
tree | 155514d7fc18d47ca0054dcd53363266699025e3 /plugins/VersionUpgrade/VersionUpgrade42to43 | |
parent | e56e355e7963c015046f271e6e50a09c952b8170 (diff) |
Named the imade profiles back again and added upgrade step for it
The proposed new name is better and since we have an upgrader now, it's best to change it.
Diffstat (limited to 'plugins/VersionUpgrade/VersionUpgrade42to43')
-rw-r--r-- | plugins/VersionUpgrade/VersionUpgrade42to43/VersionUpgrade42to43.py | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/plugins/VersionUpgrade/VersionUpgrade42to43/VersionUpgrade42to43.py b/plugins/VersionUpgrade/VersionUpgrade42to43/VersionUpgrade42to43.py index 035d53ee02..134e7ab37d 100644 --- a/plugins/VersionUpgrade/VersionUpgrade42to43/VersionUpgrade42to43.py +++ b/plugins/VersionUpgrade/VersionUpgrade42to43/VersionUpgrade42to43.py @@ -4,7 +4,15 @@ from typing import Tuple, List from UM.VersionUpgrade import VersionUpgrade -_renamed_profiles = { } +_renamed_profiles = {"generic_pla_0.4_coarse": "jbo_generic_pla_0.4_coarse", + "generic_pla_0.4_fine": "jbo_generic_pla_fine", + "generic_pla_0.4_medium": "jbo_generic_pla_medium", + "generic_pla_0.4_ultrafine": "jbo_generic_pla_ultrafine", + + "generic_petg_0.4_coarse": "jbo_generic_petg_0.4_coarse", + "generic_petg_0.4_fine": "jbo_generic_petg_fine", + "generic_petg_0.4_medium": "jbo_generic_petg_medium", + } ## Upgrades configurations from the state they were in at version 4.2 to the @@ -59,6 +67,9 @@ class VersionUpgrade42to43(VersionUpgrade): if quality_id.endswith("_2-fans"): parser["containers"]["2"] = quality_id.replace("_2-fans", "") + if parser["containers"]["2"] in _renamed_profiles: + parser["containers"]["2"] = _renamed_profiles[parser["containers"]["2"]] + material_id = parser["containers"]["3"] if material_id.endswith("_2-fans"): parser["containers"]["3"] = material_id.replace("_2-fans", "") |