@@ -131,8 +131,10 @@ def dir_assert(file, msg):
131
131
from weasyprint .text .fonts import FontConfiguration
132
132
builder = 'singlehtml'
133
133
134
- source_files = {'app.umd.js' , 'app.umd.js.map' , 'app.min.css' ,
135
- 'app.min.css.map' }
134
+ source_files = {'app.umd.js' , 'app.umd.js.map' ,
135
+ 'app.min.css' , 'app.min.css.map' ,
136
+ 'extra.umd.js' , 'extra.umd.js.map' ,
137
+ 'extra.min.css' , 'extra.min.css.map' }
136
138
cwd_ = getcwd ()
137
139
138
140
def signal_handler (sig , frame ):
@@ -170,8 +172,8 @@ def fetch_compiled(path_):
170
172
for d in listdir (dist ):
171
173
break
172
174
for f in source_files :
173
- src = path .join (dist , d , cosmic_static , f )
174
- dest = path .join (path_ , cosmic_static , f )
175
+ src = path .join (dist , d , static_path , f )
176
+ dest = path .join (path_ , static_path , f )
175
177
copy (src , dest )
176
178
rmtree (dist )
177
179
click .echo ("Success fetching the pre-compiled files!" )
@@ -194,9 +196,13 @@ def fetch_compiled(path_):
194
196
if symbolic_assert (rollup_bin , log ['node_' ].format (rollup_bin )):
195
197
return
196
198
else :
197
- comp_js = path .abspath (path .join (static_path , 'app.umd.js' ))
198
- comp_css = path .abspath (path .join (static_path , 'app.min.css' ))
199
- if not path .isfile (comp_js ) or not path .isfile (comp_css ):
199
+ with_sources = True
200
+ for s in source_files :
201
+ comp_ = path .abspath (path .join (par_dir , static_path , s ))
202
+ if not path .isfile (comp_ ):
203
+ with_sources = False
204
+
205
+ if not with_sources :
200
206
click .echo (log ['comp' ])
201
207
if which ("node" ) is None :
202
208
click .echo (log ['node_alt' ])
0 commit comments