From 8d18b1b66b2f99db3a6f4917a37432a60507b2a8 Mon Sep 17 00:00:00 2001 From: Jorge Martinez Date: Tue, 2 Jul 2024 13:41:39 +0200 Subject: [PATCH] doc: update landing page --- README.rst | 4 ---- doc/source/conf.py | 7 ++++++ doc/source/index.rst | 56 +++++++++++++++++++++++++++++++++++++------- doc/source/links.rst | 7 ++++++ 4 files changed, 61 insertions(+), 13 deletions(-) create mode 100644 doc/source/links.rst diff --git a/README.rst b/README.rst index 099486a07..48d728d09 100644 --- a/README.rst +++ b/README.rst @@ -1,11 +1,7 @@ -.. _ref_readme: - ########## PyAdditive ########## -.. readme_start - |pyansys| |python| |pypi| |GH-CI| |codecov| |MIT| |black| .. |pyansys| image:: https://img.shields.io/badge/Py-Ansys-ffc107.svg?logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAACQkWg2AAABDklEQVQ4jWNgoDfg5mD8vE7q/3bpVyskbW0sMRUwofHD7Dh5OBkZGBgW7/3W2tZpa2tLQEOyOzeEsfumlK2tbVpaGj4N6jIs1lpsDAwMJ278sveMY2BgCA0NFRISwqkhyQ1q/Nyd3zg4OBgYGNjZ2ePi4rB5loGBhZnhxTLJ/9ulv26Q4uVk1NXV/f///////69du4Zdg78lx//t0v+3S88rFISInD59GqIH2esIJ8G9O2/XVwhjzpw5EAam1xkkBJn/bJX+v1365hxxuCAfH9+3b9/+////48cPuNehNsS7cDEzMTAwMMzb+Q2u4dOnT2vWrMHu9ZtzxP9vl/69RVpCkBlZ3N7enoDXBwEAAA+YYitOilMVAAAAAElFTkSuQmCC diff --git a/doc/source/conf.py b/doc/source/conf.py index ceec6534a..e1786dc18 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -142,6 +142,7 @@ "_build", "Thumbs.db", ".DS_Store", + "links.rst", ] # numpydoc configuration @@ -185,6 +186,12 @@ # The master toctree document. master_doc = "index" +# Common content for every RST file such us links +rst_epilog = "" +links_filepath = Path(__file__).parent.absolute() / "links.rst" +with open(links_filepath) as links_file: + rst_epilog += links_file.read() + # The suffix(es) of source filenames. source_suffix = { ".rst": "restructuredtext", diff --git a/doc/source/index.rst b/doc/source/index.rst index 16f6fd53b..db1ed085e 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -1,13 +1,51 @@ -.. - Just reuse the root readme to avoid duplicating the documentation. - Provide any documentation specific to your online documentation - here. - PyAdditive documentation |version| -=================================== +################################### + +PyAdditive provides a Python API to interact with `Ansys Additive`_. + + +.. grid:: 2 + + .. grid-item-card:: Getting started :fa:`person-running` + :link: getting-started + :link-type: doc + + Step-by-step guidelines on how to set up your environment to work with + PyAdditive. -.. include:: ../../README.rst - :start-after: .. readme_start + .. grid-item-card:: User guide :fa:`book-open-reader` + :link: user-guide + :link-type: doc + + Learn about the capabilities, features, and key topics in PyAdditive. + This guide provides useful background information and explanations. + +.. jinja:: main_toctree + + {% if build_api or build_examples %} + .. grid:: 2 + + {% if build_api %} + .. grid-item-card:: API reference :fa:`book-bookmark` + :link: api/index + :link-type: doc + + A detailed guide describing the PyAdditive API. This guide documents + all the methods and properties for each interface, class, and + enumerations of each PyAdditive module. + {% endif %} + + {% if build_examples %} + .. grid-item-card:: Gallery of examples :fa:`laptop-code` + :link: examples/gallery_examples/index + :link-type: doc + + Learn how to use PyAdditive for creating custom applications and + automating your existing Additive workflows. This guide contains a + gallery of examples showing how to integrate PyAdditive with other + popular tools in the Python ecosystem. + {% endif %} + {% endif %} .. jinja:: main_toctree @@ -22,4 +60,4 @@ PyAdditive documentation |version| {% if build_examples %} examples/gallery_examples/index {% endif %} - contributing \ No newline at end of file + contributing diff --git a/doc/source/links.rst b/doc/source/links.rst new file mode 100644 index 000000000..1afe13751 --- /dev/null +++ b/doc/source/links.rst @@ -0,0 +1,7 @@ +.. PyAdditive Repository Links + +.. _PyAdditive repository: https://github.com/ansys/pyadditive + +.. Ansys products + +.. _Ansys Additive: https://www.ansys.com/products/additive