Nils
5 years ago
4 changed files with 4 additions and 56 deletions
@ -1,56 +0,0 @@ |
|||
#! /usr/bin/env python3 |
|||
# -*- coding: utf-8 -*- |
|||
|
|||
""" |
|||
This documentation is licensed under Creative Commons-BY-SA-4.0. |
|||
Please read the provided documentation/LICENSE file or visit |
|||
https://creativecommons.org/licenses/by-sa/4.0/legalcode |
|||
|
|||
The documentation is built statically and does not belong to the normal build process with configure and make |
|||
Its updating is part of the development process, not packaging and running. |
|||
The correct out/ dir is already part of git. |
|||
|
|||
.adoc is asciidoctor, not simple asciidoc. |
|||
""" |
|||
|
|||
|
|||
#Make the readme |
|||
|
|||
import sys |
|||
sys.path.append("../../engine") |
|||
from config import METADATA |
|||
from subprocess import run |
|||
from os import getcwd |
|||
import os.path |
|||
assert os.path.exists(os.path.join(getcwd(), __file__)), (getcwd(), __file__) |
|||
|
|||
|
|||
#Readme |
|||
|
|||
with open("readme.template", "r") as r: |
|||
template_lektor = r.read() |
|||
|
|||
template_lektor = """ |
|||
_model: software |
|||
--- |
|||
title: <name> |
|||
--- |
|||
year: <year> |
|||
--- |
|||
version: <version> |
|||
--- |
|||
logo: <shortname>.png |
|||
--- |
|||
body: <description> |
|||
""" |
|||
|
|||
|
|||
template_lektor = template_lektor.replace("<name>", METADATA["name"]) |
|||
template_lektor = template_lektor.replace("<version>", METADATA["version"]) |
|||
template_lektor = template_lektor.replace("<shortname>", METADATA["shortName"]) |
|||
template_lektor = template_lektor.replace("<description>", METADATA["description"]) |
|||
template_lektor = template_lektor.replace("<dependencies>", METADATA["dependencies"]) |
|||
template_lektor = template_lektor.replace("<author>", METADATA["author"]) |
|||
template_lektor = template_lektor.replace("<year>", METADATA["year"]) |
|||
|
|||
print (template_lektor) |
Loading…
Reference in new issue