更新 build.py
This commit is contained in:
parent
8dff2f9ffd
commit
02e755f236
7
build.py
7
build.py
|
@ -1,4 +1,3 @@
|
|||
|
||||
import os
|
||||
####################################
|
||||
## CONFIG/配置 ##
|
||||
|
@ -44,15 +43,15 @@ print()
|
|||
print("Write to sitemap.xml ...")
|
||||
xml_tmpl_start = """<?xml version="1.0" encoding="UTF-8"?>
|
||||
<urlset>
|
||||
<url>
|
||||
"""
|
||||
xml_tmpl_link = """
|
||||
<url>
|
||||
<loc>{}</loc>
|
||||
<changefreq>daily</changefreq>
|
||||
<priority>0.9</priority>
|
||||
</url>
|
||||
"""
|
||||
xml_tmpl_end = """ </url>
|
||||
</urlset>
|
||||
xml_tmpl_end = """</urlset>
|
||||
"""
|
||||
with open(roots+os.sep+"sitemap.xml", "w") as file:
|
||||
file.write(xml_tmpl_start)
|
||||
|
|
Loading…
Reference in New Issue