Skip to content

Commit

Permalink
WIP: Adding docs #3
Browse files Browse the repository at this point in the history
  • Loading branch information
Shihab-Shahriar committed Oct 9, 2023
1 parent f272de6 commit 4a842ff
Showing 1 changed file with 18 additions and 5 deletions.
23 changes: 18 additions & 5 deletions docs/sphinx/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,24 @@
# import sys
# sys.path.insert(0, os.path.abspath('.'))

import subprocess
return_code = subprocess.call('cd .. ; doxygen', shell=True)

if return_code != 0:
raise RuntimeError('Doxygen failed with return code {0}'.format(return_code))
import subprocess, os

# Check if we're running on Read the Docs' servers
read_the_docs_build = os.environ.get('READTHEDOCS', None) == 'True'

if read_the_docs_build:
print('Running on Read the Docs..')
return_code = subprocess.call('cd .. ; doxygen', shell=True)
if return_code != 0:
raise RuntimeError('Doxygen failed with return code {0}'.format(return_code))
# make sure output directory exists
files = os.listdir('../build/html')
print('Files in ../build/html:')
print('\n'.join(files))
else:
print('Not running on Read the Docs..')

subprocess.call('touch *.rst', shell=True)

# -- Project information -----------------------------------------------------

Expand Down

0 comments on commit 4a842ff

Please sign in to comment.