command fix

This commit is contained in:
leo 2023-02-28 17:53:23 +01:00
parent 41da658af8
commit 6ce3b3a5b7
Signed by: leo
GPG Key ID: 0DD993BFB2B307DB

View File

@ -12,7 +12,6 @@ return : The name of the folder containing the cloned repo
PATH_PREFIX = "/var/lib/gitea/git/repositories"
CACHE_FOLDER_PATH = "/var/lib/gitea/markdown_cache"
#PATH_PREFIX = ".."
import sys
import subprocess
@ -34,5 +33,5 @@ if not os.path.isdir(CACHE_FOLDER_PATH):
if not os.path.isdir(repo_name):
subprocess.run(["git", "clone", repo_path, repo_name], check=True, stdout=subprocess.DEVNULL, stderr=subprocess.STDOUT)
subprocess.run(["asciidoctor", "-s", "-a", "showtitle", "--out-file=-", f"--base-dir={repo_name}"], stdin=sys.stdin, stdout=sys.stdout)
subprocess.run(["asciidoctor", "-s", "-a", "showtitle", "--out-file=-", f"--base-dir={repo_name}", "-"])