build/others
This commit is contained in:
parent
0eb556f759
commit
fa291641e5
1 changed files with 7 additions and 3 deletions
10
build.py
10
build.py
|
@ -2,21 +2,26 @@
|
||||||
|
|
||||||
import os
|
import os
|
||||||
import shutil
|
import shutil
|
||||||
|
import subprocess
|
||||||
|
|
||||||
import sphinx
|
import sphinx
|
||||||
|
|
||||||
|
TRAVAUX = ['blanc']
|
||||||
INPUT = ["cnam"]
|
INPUT = ["cnam"]
|
||||||
OUTPUT = "out"
|
OUTPUT = "out"
|
||||||
|
|
||||||
|
|
||||||
def others():
|
def others():
|
||||||
import cnam.travaux.blanc.build as blanc
|
travaux = os.path.join('cnam', 'travaux')
|
||||||
blanc.main()
|
for travail in TRAVAUX:
|
||||||
|
subprocess.call([os.path.join(travaux, travail, 'build.py')])
|
||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
file = os.path.realpath(__file__)
|
file = os.path.realpath(__file__)
|
||||||
directory = os.path.dirname(file)
|
directory = os.path.dirname(file)
|
||||||
|
os.chdir(directory)
|
||||||
|
others()
|
||||||
output_directory = os.path.join(directory, OUTPUT)
|
output_directory = os.path.join(directory, OUTPUT)
|
||||||
shutil.rmtree(output_directory, ignore_errors=True)
|
shutil.rmtree(output_directory, ignore_errors=True)
|
||||||
for doc in INPUT:
|
for doc in INPUT:
|
||||||
|
@ -33,7 +38,6 @@ def main():
|
||||||
os.path.join(output_directory, doc),
|
os.path.join(output_directory, doc),
|
||||||
]
|
]
|
||||||
sphinx.build_main(arguments)
|
sphinx.build_main(arguments)
|
||||||
others()
|
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue