Skip to content

Commit 0f002e5

Browse files
authored
add basic example workflow (#13)
* add basic example workflow * add basic starting guide * spelling fixes * libary --> library
1 parent 0aeebca commit 0f002e5

File tree

14 files changed

+82
-22
lines changed

14 files changed

+82
-22
lines changed

doc/source/abstraction/app_interface_abstraction.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ that is structured around data represented as classes and methods.
99
PyAnsys seeks to make the API a "first class citizen" in regard to
1010
interacting with an Ansys product by presenting the product as a
1111
stateful data model. Consider the following comparison between using a
12-
recorded script from AEDT versus using the PyAEDT libary to create an
12+
recorded script from AEDT versus using the PyAEDT library to create an
1313
open region in the active editor:
1414

1515
+------------------------------------------------------+----------------------------------------------+

doc/source/coding_style/best_practices.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
Best Practices
44
==============
55
The following sections summarize the key points from `PEP8`_ and how
6-
they apply to PyAnsys libaries. The goal is for PyAnsys libraries to
6+
they apply to PyAnsys libraries. The goal is for PyAnsys libraries to
77
be consistent in style and formatting with the "big three"
88
data science libraries: `NumPy`_, `SciPy`_, and `pandas`_.
99

doc/source/coding_style/flake8.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ The above configuration defines the following options:
7070
This denotes the maximum line length for any one line of code.
7171
The `PEP8`_ standard advises a maximum line length of 79. Because
7272
this is a bit limiting in some cases, the maximum line length
73-
recommended for a PyAnsys libary is 100.
73+
recommended for a PyAnsys library is 100.
7474

7575
- ``statistics``
7676
This enables the number of occurrences of each error or warning code
@@ -104,7 +104,7 @@ base.
104104
Utilizing Black
105105
~~~~~~~~~~~~~~~
106106
Manually checking for code styling can be a tedious task. Luckily,
107-
several Python tools for autoformatting code to meet PEP8 standards
107+
several Python tools for auto-formatting code to meet PEP8 standards
108108
are available to help with this. The PyAnsys project suggests the use of the
109109
the formatting tool `black`_.
110110

@@ -120,7 +120,7 @@ done with the tool `pre-commit`_. Setting up a `pre-commit hook
120120
to run black <https://black.readthedocs.io/en/stable/integrations/source_version_control.html>`_
121121
will automatically format the code before committing. This simple way of
122122
incorporating code style checks into the development workflow to maintain
123-
PEP8 guidelines requires mininmal manual effort.
123+
PEP8 guidelines requires minimal manual effort.
124124

125125
.. _pre-commit: https://pre-commit.com/
126126

doc/source/coding_style/index.rst

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@ data science libraries: `NumPy`_, `SciPy`_, and `pandas`_.
1313
.. _PEP8: https://www.python.org/dev/peps/pep-0008/
1414

1515

16-
TODO:
16+
.. todo::
1717

18-
* Describe flake8 standards (in subpage), include example ``.flake8``
19-
with minimum standards.
20-
* Include anythin we've written from other documentation either in
21-
this page or other pages.
18+
* Describe flake8 standards (in subpage), include example ``.flake8``
19+
with minimum standards.
20+
* Include anything we've written from other documentation either in
21+
this page or other pages.
2222

2323
.. toctree::
2424
:hidden:

doc/source/conf.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616

1717
# Sphinx extensions
1818
extensions = [
19+
'sphinx.ext.todo',
1920
'sphinx.ext.autodoc',
2021
'sphinx.ext.napoleon',
2122
'sphinx.ext.autosummary',

doc/source/documentation_style/index.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Documentation Style
55
Good documentation drives library adoption and usage and is the
66
foundation for a good developer experience. Even with the best
77
interfaces and the most functional product, no one will adopt the API
8-
if they don't know how to use it or if they aren't satisifed with the
8+
if they don't know how to use it or if they aren't satisfied with the
99
documentation or examples they are presented with.
1010

1111
Good API documentation provides:

doc/source/library_description/index.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ The template repository contains a generalized library skeleton that includes:
4747
- Library skeleton with sample classes and methods
4848
- Sample documentation build including customized templates
4949
- Sample GitHub actions specific to PyAnsys libraries
50-
- Licensing, example readme, and setup files
50+
- Licensing, example README, and setup files
5151
- ``.gitignore`` and other requirements files
5252

5353
To use this template, `create a repository from a template`_.

doc/source/library_description/library_names.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ these naming conventions:
99
is the project name for AEDT.
1010
- The repository name as hosted on GitHub should be all
1111
lowercase to follow GitHub community standards. For
12-
exmaple, `pymapdl`_ and `pyaedt`_.
12+
example, `pymapdl`_ and `pyaedt`_.
1313
- The Python library name is to be in the format
1414
``ansys-<product/service>-<feature>``. For example,
1515
`ansys-mapdl-core <https://pypi.org/project/ansys-mapdl-core/>`_

doc/source/library_description/packaging.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ Install a package with:
129129
130130
pip install ansys.<product>.<library>
131131
132-
To create a package complying with the above standards, here is the minimal content of your PyAnsys libary:
132+
To create a package complying with the above standards, here is the minimal content of your PyAnsys library:
133133

134134
.. code::
135135

doc/source/overview/administration.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,9 +86,9 @@ Major releases denote global, major breaking API changes. Adding or
8686
changing a feature is not considered a globally-backwards incompatible
8787
API change. Rather, a major release and version bump should be made
8888
if globally-breaking changes are made that will require a
89-
signifiant refactor of any dependent modules.
89+
significant refactor of any dependent modules.
9090

91-
Note that ``0.MINOR.PATCH`` packges are expected to have fluid
91+
Note that ``0.MINOR.PATCH`` packages are expected to have fluid
9292
APIs and should be solidified at the ``1.MINOR.PATCH`` release. At
9393
that point, APIs are expected to be much more stable.
9494

doc/source/overview/basic.rst

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
Quick Start Guide
2+
=================
3+
4+
This is a brief overview on how to get started right away with your own PyAnsys library on the `PyAnsys GitHub Organization`_
5+
6+
#. **Create the Repository:** Create a new repository from the
7+
`pyansys/template`_. See
8+
`Creating a repository from a template`_. Be sure to start as a
9+
private repository.
10+
11+
#. **Rename the Package:** Rename ``ansys/product/library`` to match
12+
your product or library. For example ``ansys/mapdl/core``. Do the
13+
same in ``setup.py``. Do this as a pull request. In fact, only add
14+
code as pull requests (don't push to main).
15+
16+
#. **Add Source:** Add your source files to
17+
``ansys/<product>/<library>``, or create them. At the same time,
18+
add unit tests to ``tests/`` following the `pytest`_ convention.
19+
Be sure to maintain sufficient coverage when adding your library.
20+
See `pytest-cov`_.
21+
22+
.. note::
23+
If your tests require an active service,
24+
application, or product, be sure to setup this application to run
25+
in an automated manner.
26+
27+
#. **Documentation:** Update documentation at ``doc/``. There are two
28+
types of docs, User-Guide and API. Be sure that both are updated.
29+
See :ref:`api_documentation`.
30+
31+
#. **Package Release:** When ready to release your package publicly,
32+
contact [email protected] to obtain the release
33+
checklist in regards to official Ansys approval. Once the
34+
checklist is complete, change the `repository visibility`_,
35+
create a release branch.
36+
37+
The manner of the source and content of the documentation will vary
38+
from project to project.
39+
40+
.. todo::
41+
42+
gRPC - Starting Guide
43+
44+
.. todo::
45+
46+
C Extension - Starting Guide
47+
48+
.. todo::
49+
50+
Others like requests, RPC, COM, etc.
51+
52+
53+
.. _pytest-cov: https://pytest-cov.readthedocs.io/en/latest/reporting.html
54+
.. _pyansys/template: https://github.com/pyansys/template
55+
.. _Creating a repository from a template: https://docs.github.com/en/repositories/creating-and-managing-repositories/creating-a-repository-from-a-template
56+
.. _repository visibility: https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/managing-repository-settings/setting-repository-visibility
57+
.. _PyAnsys GitHub Organization: https://github.com/pyansys
58+
.. _pytest: https://pytest.org/

doc/source/overview/contributing.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ contributing to a PyAnsys library.
77

88
We welcome all code contributions and hope that this developer's guide
99
facilitates an understanding of the PyAnsys code repository. It is important to
10-
note that while Ansys maintains all PyAnsys libaries and thoroughly reviews all
10+
note that while Ansys maintains all PyAnsys libraries and thoroughly reviews all
1111
submissions before merging, our goal is to foster a community that can support
12-
user questions and develop new features to make PyAnsys libaries powerful tools
12+
user questions and develop new features to make PyAnsys libraries powerful tools
1313
for all users. As such, we welcome and encourage the submittal of questions and
1414
code to this repository and all PyAnsys library repositories.
1515

@@ -52,7 +52,7 @@ screenshot, and sample files to help us address the issue.
5252

5353
Issues
5454
------
55-
For general or technical questions about a PyAnsys libary, its applications, or
55+
For general or technical questions about a PyAnsys library, its applications, or
5656
about software usage, you can create issues for the applicable repository at:
5757

5858
- `PyAEDT Issues <https://github.com/pyansys/pyaedt/issues>`_
@@ -95,7 +95,7 @@ For example:
9595
pip install -e .
9696
9797
Consider creating a fork of the repository if you want to eventually
98-
push a contribution to the offical PyAnsys repository.
98+
push a contribution to the official PyAnsys repository.
9999

100100
.. https://docs.github.com/en/get-started/quickstart/fork-a-repo
101101

doc/source/overview/dev_practices.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ Consider the following general coding paradigms when contributing:
5252
guidelines, and always provide an example of simple use cases for
5353
new features.
5454

55-
3. **Test it**. Because Python is an interperted language, if it's not
55+
3. **Test it**. Because Python is an interpreted language, if it's not
5656
tested, it's probably broken. At the minimum, include unit tests
5757
for each new feature within the ``tests`` directory. Ensure that
5858
each new method, class, or function has reasonable (>80%) coverage.
@@ -143,7 +143,7 @@ Procedures follow for major and minor releases.
143143
production. Any bugs identified should have their hotfixes pushed to
144144
this release branch.
145145

146-
#. When the branch is deemed as stable for public release, the PR ismerged
146+
#. When the branch is deemed as stable for public release, the PR is merged
147147
to `main` branch, which is then tagged with a `MAJOR.MINOR.0` release.
148148
The release branch will not be deleted.
149149

doc/source/overview/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ PROTO files, create coverage reports, and report on system coverage:
6363
:hidden:
6464
:maxdepth: 3
6565

66+
basic
6667
administration
6768
contributing
6869
dev_practices

0 commit comments

Comments
 (0)