View Single Post
Old 01-06-2022, 12:33 PM   #30
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,883
Karma: 6120478
Join Date: Nov 2009
Device: many
Your best bet is to write a script that uses a stream editor like sed to extract the style tag from head in each xhtml file and replace it with a link to a new stylesheet you will fill with the extracted styles, one for each xhtml file.

Alternatively, you can readily do this in a plugin since they support a number of parsers including quick parser, gumbo, and bs4.
KevinH is offline   Reply With Quote