From d2ff7dbaaa5de3d25b2a4787b9147b1b92bb12eb Mon Sep 17 00:00:00 2001 From: Ray Speth Date: Tue, 8 Apr 2014 16:26:11 +0000 Subject: [PATCH] [SCons] 'clean' removes auto-generated .rst files from examples --- .gitignore | 4 ++-- SConstruct | 2 ++ doc/SConscript | 4 ++-- doc/sphinx/cython/{examples => }/example-script.rst.in | 0 doc/sphinx/matlab/{examples => }/example-script.rst.in | 0 5 files changed, 6 insertions(+), 4 deletions(-) rename doc/sphinx/cython/{examples => }/example-script.rst.in (100%) rename doc/sphinx/matlab/{examples => }/example-script.rst.in (100%) diff --git a/.gitignore b/.gitignore index f01b81e36..eb1c8849a 100644 --- a/.gitignore +++ b/.gitignore @@ -34,5 +34,5 @@ config.log *.gcno coverage/ coverage.info -doc/sphinx/cython/examples/*.rst -doc/sphinx/matlab/examples/*.rst +doc/sphinx/cython/examples +doc/sphinx/matlab/examples diff --git a/SConstruct b/SConstruct index 3037e07b0..04a64d1a8 100644 --- a/SConstruct +++ b/SConstruct @@ -54,6 +54,8 @@ if 'clean' in COMMAND_LINE_TARGETS: removeFile('.sconsign.dblite') removeFile('include/cantera/base/config.h') removeFile('ext/f2c_libs/arith.h') + removeDirectory('doc/sphinx/matlab/examples') + removeDirectory('doc/sphinx/cython/examples') for name in os.listdir('.'): if name.endswith('.msi'): removeFile(name) diff --git a/doc/SConscript b/doc/SConscript index 141aeef55..3f80d9a94 100644 --- a/doc/SConscript +++ b/doc/SConscript @@ -32,7 +32,7 @@ if localenv['sphinx_docs']: tmpenv['script_name'] = f.name tmpenv['script_path'] = '../../../../interfaces/cython/cantera/examples/%s/%s' % (subdir, f.name) b = tmpenv.SubstFile('#doc/sphinx/cython/examples/%s_%s.rst' % (subdir, f.name[:-3]), - '#doc/sphinx/cython/examples/example-script.rst.in') + '#doc/sphinx/cython/example-script.rst.in') build(b) localenv.Depends(sphinxdocs, b) @@ -43,7 +43,7 @@ if localenv['sphinx_docs']: tmpenv['script_name'] = f.name tmpenv['script_path'] = '../../../../samples/matlab/%s' % f.name b = tmpenv.SubstFile('#doc/sphinx/matlab/examples/%s.rst' % f.name[:-2], - '#doc/sphinx/matlab/examples/example-script.rst.in') + '#doc/sphinx/matlab/example-script.rst.in') build(b) localenv.Depends(sphinxdocs, b) diff --git a/doc/sphinx/cython/examples/example-script.rst.in b/doc/sphinx/cython/example-script.rst.in similarity index 100% rename from doc/sphinx/cython/examples/example-script.rst.in rename to doc/sphinx/cython/example-script.rst.in diff --git a/doc/sphinx/matlab/examples/example-script.rst.in b/doc/sphinx/matlab/example-script.rst.in similarity index 100% rename from doc/sphinx/matlab/examples/example-script.rst.in rename to doc/sphinx/matlab/example-script.rst.in