Set file path for generated README.rst
README.rst could previously be generated by running readme.py only from inside the scripts directory. This patch lets the script be run from anywhere by taking the real path of the readme.py Change-Id: Icd074bddbc9311b852e42be86d78c3dae82897d8
This commit is contained in:
parent
697843eaa7
commit
45d507d6f5
|
@ -59,7 +59,10 @@ def find_docs():
|
|||
|
||||
def concat_docs():
|
||||
"""Concatinates files yielded by the generator `find_docs`."""
|
||||
outfile = "../README.rst"
|
||||
file_path = os.path.dirname(os.path.realpath(__file__))
|
||||
head, tail = os.path.split(file_path)
|
||||
outfile = head +"/README.rst"
|
||||
|
||||
if not os.path.isfile(outfile):
|
||||
print("../README.rst not found, exiting!")
|
||||
exit(1)
|
||||
|
|
Loading…
Reference in New Issue