diff --git a/core/docs/README.md b/core/docs/README.md index a2fc8cc23..84961862d 100644 --- a/core/docs/README.md +++ b/core/docs/README.md @@ -25,9 +25,5 @@ The `State` is the object that holds every information needed for the simulation ### Further information * [Input File Reference](Input.md) -* [How to: Energy minimisation](Use_Minimisation.md) -* [How to: LLG dynamics](Use_LLG.md) -* [How to: GNEB](Use_GNEB.md) -* [How to: HTST](Use_HTST.md) -* [How to: MMF](Use_MMF.md) -* [Input File Reference](Input.md) \ No newline at end of file +* [C API Examples](C_API.md) +* [Python API Examples](Python_API.md) \ No newline at end of file diff --git a/core/docs/c-api/API_Reference.rst b/core/docs/c-api/API_Reference.rst index c9a115d00..4a51cfe2b 100644 --- a/core/docs/c-api/API_Reference.rst +++ b/core/docs/c-api/API_Reference.rst @@ -21,4 +21,4 @@ Full API reference Spirit/Simulation.h Spirit/State.h Spirit/System.h - Spirit/Transition.h \ No newline at end of file + Spirit/Transitions.h \ No newline at end of file diff --git a/conf.py b/docs/conf.py similarity index 94% rename from conf.py rename to docs/conf.py index 609298081..a78b537ca 100644 --- a/conf.py +++ b/docs/conf.py @@ -80,7 +80,7 @@ # The master toctree document. -master_doc = 'docs/index' +master_doc = 'index' # man_pages = [ master_doc, ("docs/BUILD", "build", "building", "authors", "sectionbuild") ] @@ -222,7 +222,7 @@ def run_apidoc(_): build on readthedocs. See also https://github.com/rtfd/readthedocs.org/issues/1139 """ - source_dir = os.path.abspath(os.path.dirname(__file__)) + source_dir = os.path.join(os.path.abspath(os.path.dirname(__file__)), '..') apidoc_dir = os.path.join(source_dir, 'core', 'docs', 'python-api') package_dir = os.path.join(source_dir, 'core', 'python', 'spirit') @@ -242,20 +242,20 @@ def run_apidoc(_): '--maxdepth', '4', ] - builddir = os.path.join(source_dir, 'build') - if not os.path.exists(builddir): - os.mkdir(builddir) - subprocess.check_call(['cmake', '..', '-DSPIRIT_BUILD_FOR_CXX=OFF', '-DSPIRIT_SKIP_HTST=ON'], cwd=builddir) - subprocess.check_call(['make'], cwd=builddir) + build_dir = os.path.join(source_dir, 'build') + if not os.path.exists(build_dir): + os.mkdir(build_dir) + subprocess.check_call(['cmake', '..', '-DSPIRIT_BUILD_FOR_CXX=OFF', '-DSPIRIT_SKIP_HTST=ON'], cwd=build_dir) + subprocess.check_call(['make'], cwd=build_dir) # See https://stackoverflow.com/a/30144019 env = os.environ.copy() env["SPHINX_APIDOC_OPTIONS"] = 'members,special-members,private-members,undoc-members,show-inheritance' - subprocess.check_call([cmd_path] + options, env=env) + subprocess.check_call([cmd_path] + options, env=env, cwd=source_dir) ##################### with open(os.path.join(apidoc_dir, 'parameters.rst'), "w") as parameters_file: - parameters_file.write("Parameters\n==================================\n\n") + parameters_file.write("spirit.parameters\n==================================\n\n") with open(os.path.join(apidoc_dir, 'spirit.parameters.mc.rst'), 'r') as generated_file: parameters_file.write(generated_file.read()) with open(os.path.join(apidoc_dir, 'spirit.parameters.llg.rst'), 'r') as generated_file: