Skip to content

Commit edc5bd0

Browse files
authored
Merge pull request #139 from cadenmyers13/rst-migration
skpkg: Update rst files, copyright year in license, and `autodoc_mock_import`
2 parents ae4906e + 4f5d7a7 commit edc5bd0

File tree

10 files changed

+69
-40
lines changed

10 files changed

+69
-40
lines changed

.gitignore

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ __pycache__/
1010
.Python
1111
env/
1212
build/
13+
_build/
1314
develop-eggs/
1415
dist/
1516
downloads/
@@ -90,10 +91,3 @@ target/
9091

9192
# Ipython Notebook
9293
.ipynb_checkpoints
93-
94-
# version information
95-
setup.cfg
96-
/src/diffpy/*/version.cfg
97-
98-
# Rever
99-
rever/

CHANGELOG.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
=============
2-
Release Notes
2+
Release notes
33
=============
44

55
.. current developments
@@ -65,7 +65,7 @@ Release Notes
6565
* No notable functional changes from 1.4.1
6666

6767
1.4.4rc0
68-
=====
68+
========
6969

7070
**Fixed:**
7171

LICENSE.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ the following paper in your publication:
1313
in crystals (https://stacks.iop.org/0953-8984/19/335219), *J. Phys.: Condens. Matter*, 19, 335219 (2007)
1414

1515
Copyright 2006-2007, Board of Trustees of Michigan State University,
16-
Copyright 2008-2024, Board of Trustees of Columbia University in the
16+
Copyright 2008-2025, Board of Trustees of Columbia University in the
1717
city of New York. (Copyright holder indicated in each source file).
1818

1919
For more information please visit the project web-page:

README.rst

Lines changed: 20 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
:target: https://diffpy.github.io/diffpy.pdffit2
99
:height: 100px
1010

11-
|PyPi| |Forge| |PythonVersion| |PR|
11+
|PyPI| |Forge| |PythonVersion| |PR|
1212

1313
|CI| |Codecov| |Black| |Tracking|
1414

@@ -26,7 +26,7 @@
2626

2727
.. |PR| image:: https://img.shields.io/badge/PR-Welcome-29ab47ff
2828

29-
.. |PyPi| image:: https://img.shields.io/pypi/v/diffpy.pdffit2
29+
.. |PyPI| image:: https://img.shields.io/pypi/v/diffpy.pdffit2
3030
:target: https://pypi.org/project/diffpy.pdffit2/
3131

3232
.. |PythonVersion| image:: https://img.shields.io/pypi/pyversions/diffpy.pdffit2
@@ -87,19 +87,17 @@ The preferred method is to use `Miniconda Python
8787
<https://docs.conda.io/projects/miniconda/en/latest/miniconda-install.html>`_
8888
and install from the "conda-forge" channel of Conda packages.
8989

90-
Add the "conda-forge" channel by running the following command in a terminal: ::
90+
To add "conda-forge" to the conda channels, run the following in a terminal. ::
9191

9292
conda config --add channels conda-forge
9393

94-
Create a new environment named ``diffpy.pdffit2_env`` and install ``diffpy.pdffit2``: ::
94+
We want to install our packages in a suitable conda environment.
95+
The following creates and activates a new environment named ``diffpy.pdffit2_env`` ::
9596

9697
conda create -n diffpy.pdffit2_env diffpy.pdffit2
97-
98-
Activate the environment: ::
99-
10098
conda activate diffpy.pdffit2_env
10199

102-
Confirm that the installation was successful: ::
100+
To confirm that the installation was successful, type ::
103101

104102
python -c "import diffpy.pdffit2; print(diffpy.pdffit2.__version__)"
105103

@@ -118,25 +116,20 @@ Install pdffit2 using ``pip`` to download and install the latest version from `P
118116

119117
pip install diffpy.pdffit2
120118

121-
Confirm that the installation was successful: ::
119+
To confirm that the installation was successful, type ::
122120

123121
python -c "import diffpy.pdffit2; print(diffpy.pdffit2.__version__)"
124122

125-
Build from source
126-
~~~~~~~~~~~~~~~~~
123+
If you prefer to install from sources, after installing the dependencies, obtain the source archive from
124+
`GitHub <https://github.com/diffpy/diffpy.pdffit2/>`_. Once installed, ``cd`` into your ``diffpy.pdffit2`` directory
125+
and run the following ::
127126

128-
For advanced users, obtain the source archive, and in the ``diffpy.pdffit2`` directory, run ::
127+
pip install .
129128

130-
conda create -n diffpy.pdffit2_env python=3.13 \
131-
--file requirements/test.txt \
132-
--file requirements/conda.txt \
133-
--file requirements/build.txt
129+
Getting Started
130+
---------------
134131

135-
Activate the environment, build the package, and run unit tests by following commands sequentially: ::
136-
137-
conda activate diffpy.pdffit2_env
138-
pip install . --no-deps
139-
pytest
132+
You may consult our `online documentation <https://diffpy.github.io/diffpy.pdffit2>`_ for tutorials and API references.
140133

141134
Support and Contribute
142135
----------------------
@@ -182,4 +175,9 @@ Before contributing, please read our `Code of Conduct <https://github.com/diffpy
182175
Contact
183176
-------
184177

185-
For more information on diffpy.pdffit2 please visit the project `web-page <https://diffpy.github.io/>`_ or email Prof. Simon Billinge at [email protected].
178+
For more information on diffpy.pdffit2 please visit the project `web-page <https://diffpy.github.io/>`_ or email Simon Billinge at [email protected].
179+
180+
Acknowledgements
181+
----------------
182+
183+
``diffpy.pdffit2`` is built and maintained with `scikit-package <https://scikit-package.github.io/scikit-package/>`_.

doc/source/api/diffpy.pdffit2.rst

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
:tocdepth: -1
22

3-
diffpy.pdffit2 package
4-
======================
3+
|title|
4+
=======
5+
6+
.. |title| replace:: diffpy.pdffit2 package
57

68
.. automodule:: diffpy.pdffit2
79
:members:

doc/source/conf.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,10 @@
5353
"m2r",
5454
]
5555

56+
autodoc_mock_imports = [
57+
"diffpy.pdffit2.pdffit2",
58+
]
59+
5660
# Add any paths that contain templates here, relative to this directory.
5761
templates_path = ["_templates"]
5862

doc/source/index.rst

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44

55
.. |title| replace:: diffpy.pdffit2 documentation
66

7-
diffpy.pdffit2 - PDFfit2 - real space structure refinement program.
7+
``diffpy.pdffit2`` - PDFfit2 - real space structure refinement program.
88

9-
| Software version |release|.
9+
| Software version |release|
1010
| Last updated |today|.
1111
1212
The diffpy.pdffit2 package provides functions for the calculation and
@@ -75,19 +75,25 @@ in your publication:
7575
Installation
7676
============
7777

78-
Please see the `README <https://github.com/diffpy/diffpy.pdffit2#installation>`_
78+
See the `README <https://github.com/diffpy/diffpy.pdffit2#installation>`_
7979
file included with the distribution.
8080

81+
================
82+
Acknowledgements
83+
================
84+
85+
``diffpy.pdffit2`` is built and maintained with `scikit-package <https://scikit-package.github.io/scikit-package/>`_.
86+
8187
=================
8288
Table of contents
8389
=================
8490
.. toctree::
8591
:titlesonly:
8692

87-
license
88-
release
8993
examples
9094
Package API <api/diffpy.pdffit2>
95+
release
96+
license
9197

9298
=======
9399
Indices

doc/source/license.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ the following paper in your publication:
1717
in crystals (https://stacks.iop.org/0953-8984/19/335219), *J. Phys.: Condens. Matter*, 19, 335219 (2007)
1818

1919
Copyright 2006-2007, Board of Trustees of Michigan State University,
20-
Copyright 2008-|year|, Board of Trustees of Columbia University in the
20+
Copyright 2008-2025, Board of Trustees of Columbia University in the
2121
city of New York. (Copyright holder indicated in each source file).
2222

2323
For more information please visit the project web-page:

news/rst-migration.rst

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
**Added:**
2+
3+
* <news item>
4+
5+
**Changed:**
6+
7+
* <news item>
8+
9+
**Deprecated:**
10+
11+
* <news item>
12+
13+
**Removed:**
14+
15+
* <news item>
16+
17+
**Fixed:**
18+
19+
* Migrate documentation to `scikit-package 0.1.0` standards, including a mock import for API rendering.
20+
21+
**Security:**
22+
23+
* <news item>

src/diffpy/pdffit2/version.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,3 +61,5 @@ def get_pypi_release_date(package_name, timeout=5):
6161
__date__ = get_pypi_release_date("diffpy.pdffit2")
6262

6363
# End of file
64+
65+
# Release date: 2025-02-07

0 commit comments

Comments
 (0)