@@ -82,16 +82,16 @@ def migrate_dir(src, dst):
82
82
"""Migrate a directory from src to dst"""
83
83
log = get_logger ()
84
84
if not os .listdir (src ):
85
- log .debug ("No files in %s" % src )
85
+ log .debug ("No files in %s" , src )
86
86
return False
87
87
if os .path .exists (dst ):
88
88
if os .listdir (dst ):
89
89
# already exists, non-empty
90
- log .debug ("%s already exists" % dst )
90
+ log .debug ("%s already exists" , dst )
91
91
return False
92
92
else :
93
93
os .rmdir (dst )
94
- log .info (f "Copying { src } -> { dst } " )
94
+ log .info ("Copying %s -> %s" , src , dst )
95
95
ensure_dir_exists (os .path .dirname (dst ))
96
96
shutil .copytree (src , dst , symlinks = True )
97
97
return True
@@ -105,9 +105,9 @@ def migrate_file(src, dst, substitutions=None):
105
105
log = get_logger ()
106
106
if os .path .exists (dst ):
107
107
# already exists
108
- log .debug ("%s already exists" % dst )
108
+ log .debug ("%s already exists" , dst )
109
109
return False
110
- log .info (f "Copying { src } -> { dst } " )
110
+ log .info ("Copying %s -> %s" , src , dst )
111
111
ensure_dir_exists (os .path .dirname (dst ))
112
112
shutil .copy (src , dst )
113
113
if substitutions :
@@ -131,7 +131,7 @@ def migrate_one(src, dst):
131
131
elif os .path .isdir (src ):
132
132
return migrate_dir (src , dst )
133
133
else :
134
- log .debug ("Nothing to migrate for %s" % src )
134
+ log .debug ("Nothing to migrate for %s" , src )
135
135
return False
136
136
137
137
@@ -163,9 +163,9 @@ def migrate_static_custom(src, dst):
163
163
custom_css_empty = css .startswith ("/*" ) and css .endswith ("*/" )
164
164
165
165
if custom_js_empty :
166
- log .debug ("Ignoring empty %s" % custom_js )
166
+ log .debug ("Ignoring empty %s" , custom_js )
167
167
if custom_css_empty :
168
- log .debug ("Ignoring empty %s" % custom_css )
168
+ log .debug ("Ignoring empty %s" , custom_css )
169
169
170
170
if custom_js_empty and custom_css_empty :
171
171
# nothing to migrate
@@ -208,7 +208,7 @@ def migrate_config(name, env):
208
208
migrated .append (src )
209
209
else :
210
210
# don't migrate empty config files
211
- log .debug ("Not migrating empty config file: %s" % src )
211
+ log .debug ("Not migrating empty config file: %s" , src )
212
212
return migrated
213
213
214
214
0 commit comments