2023-04-09 16:30:28 +00:00
|
|
|
import glob
|
|
|
|
import time
|
|
|
|
|
2023-12-28 10:48:39 +00:00
|
|
|
|
2023-04-09 16:30:28 +00:00
|
|
|
def output():
|
|
|
|
read = glob.glob("*.md")
|
|
|
|
content = ""
|
2023-06-03 19:21:43 +00:00
|
|
|
nsfw_content = ""
|
2023-04-09 16:30:28 +00:00
|
|
|
for file in read:
|
2023-12-31 09:53:57 +00:00
|
|
|
if file != "README.md" or file != "feedback.md" or file != "posts.md":
|
2023-04-09 16:30:28 +00:00
|
|
|
with open(file, "r") as f:
|
2023-12-28 10:48:39 +00:00
|
|
|
if "NSFWPiracy.md" == file:
|
2023-06-03 19:21:43 +00:00
|
|
|
nsfw_content += f.read()
|
|
|
|
continue
|
2023-04-09 16:30:28 +00:00
|
|
|
content += f.read()
|
2023-06-03 19:21:43 +00:00
|
|
|
return content + nsfw_content
|
2023-04-09 16:30:28 +00:00
|
|
|
|
2023-12-28 10:48:39 +00:00
|
|
|
|
2023-04-09 16:30:28 +00:00
|
|
|
def main():
|
|
|
|
content = output()
|
|
|
|
with open("single-page", "w") as file:
|
|
|
|
file.write(content)
|
|
|
|
|
|
|
|
|
|
|
|
if __name__ == "__main__":
|
|
|
|
s = time.perf_counter()
|
|
|
|
main()
|
|
|
|
elapsed = time.perf_counter() - s
|
|
|
|
print(f"{__file__} executed in {elapsed:0.2f} seconds.")
|