Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2020-10-02 03:10:01 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-10-02 04:59:16 +0300
commitbab9de2a52929fe2b45ecddb1eb09da3378e303b (patch)
treecde61c5cb86dfad1c90aa414a8c7b1711ec25782 /release/scripts/startup/bl_operators/userpref.py
parent28ebe827e60c84ed4731a9f8aa701ccf2d8be0b0 (diff)
Cleanup: pep8, blank lines
Diffstat (limited to 'release/scripts/startup/bl_operators/userpref.py')
-rw-r--r--release/scripts/startup/bl_operators/userpref.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/release/scripts/startup/bl_operators/userpref.py b/release/scripts/startup/bl_operators/userpref.py
index f92a231f1da..113e6b06153 100644
--- a/release/scripts/startup/bl_operators/userpref.py
+++ b/release/scripts/startup/bl_operators/userpref.py
@@ -49,6 +49,7 @@ def module_filesystem_remove(path_base, module_name):
else:
os.remove(f_full)
+
# This duplicates shutil.copytree from Python 3.8, with the new dirs_exist_ok
# argument that we need. Once we upgrade to 3.8 we can remove this.
def _preferences_copytree(entries, src, dst):
@@ -85,11 +86,13 @@ def _preferences_copytree(entries, src, dst):
raise Error(errors)
return dst
+
def preferences_copytree(src, dst):
import os
with os.scandir(src) as entries:
return _preferences_copytree(entries=entries, src=src, dst=dst)
+
class PREFERENCES_OT_keyconfig_activate(Operator):
bl_idname = "preferences.keyconfig_activate"
bl_label = "Activate Keyconfig"