Misc fixes
This commit is contained in:
@ -12,15 +12,19 @@ def generate_READMEs(app_path):
|
||||
if not os.path.exists(app_path):
|
||||
raise Exception("App path provided doesn't exists ?!")
|
||||
|
||||
manifest = json.load(open(os.path.join(app_path, "manifest.json")))
|
||||
upstream = manifest.get("upstream", {})
|
||||
|
||||
if not upstream and not os.path.exists(os.path.join(app_path, "doc", "DISCLAIMER.md")):
|
||||
print("There's no 'upstream' key in the manifest, and doc/DISCLAIMER.md doesn't exists - therefore assuming that we shall not auto-update the README.md for this app yet.")
|
||||
return
|
||||
|
||||
env = Environment(loader=FileSystemLoader('./templates'))
|
||||
|
||||
for lang, lang_suffix in [("en", ""), ("fr", "_fr")]:
|
||||
|
||||
template = env.get_template(f'README{lang_suffix}.md.j2')
|
||||
|
||||
manifest = json.load(open(os.path.join(app_path, "manifest.json")))
|
||||
upstream = manifest.get("upstream", {})
|
||||
|
||||
if os.path.exists(os.path.join(app_path, "doc", "screenshots")):
|
||||
screenshots = os.listdir(os.path.join(app_path, "doc", "screenshots"))
|
||||
if ".gitkeep" in screenshots:
|
||||
|
Reference in New Issue
Block a user