mirror of
https://github.com/simon987/sist2.git
synced 2025-04-17 01:06:43 +00:00
21 lines
563 B
Python
21 lines
563 B
Python
files = [
|
|
"src/static/css/bundle.css",
|
|
"src/static/css/bundle_dark.css",
|
|
"src/static/js/bundle.js",
|
|
"src/static/js/search.js",
|
|
"src/static/img/sprite-skin-flat.png",
|
|
"src/static/img/sprite-skin-flat-dark.png",
|
|
"src/static/search.html",
|
|
"src/static/stats.html",
|
|
]
|
|
|
|
|
|
def clean(filepath):
|
|
return filepath.split("/")[-1].replace(".", "_").replace("-", "_")
|
|
|
|
|
|
for file in files:
|
|
with open(file, "rb") as f:
|
|
data = f.read()
|
|
print("char %s[%d] = {%s};" % (clean(file), len(data), ",".join(str(int(b)) for b in data)))
|