mirror of
https://github.com/tiennm99/cheahjs-free-llm-api-resources.git
synced 2026-10-19 04:15:49 +00:00
refactor: make README file paths relative to script directory
This commit is contained in:
1 parent
8abf2d49aa
commit
1b8491153c
1 file changed
+3
-2
@@ -595,9 +595,10 @@ def main():
|
||||
print("Missing models:")
|
||||
print(list(MISSING_MODELS))
|
||||
|
||||
with open("README_template.md", "r") as f:
|
||||
script_dir = os.path.dirname(os.path.abspath(__file__))
|
||||
with open(os.path.join(script_dir, "README_template.md"), "r") as f:
|
||||
readme = f.read()
|
||||
with open("../README.md", "w") as f:
|
||||
with open(os.path.join(script_dir, "..", "README.md"), "w") as f:
|
||||
f.write(readme.replace("{{MODEL_LIST}}", table).replace("{{TRIAL_MODEL_LIST}}", trial_table))
|
||||
print("Wrote models to README.md")
|
||||
|
||||
|
||||
Reference in new issue
Block a user