Skip to content

Commit a48bb6b

Browse files
authored
Merge pull request #206 from diffpy/migration
chore: merge fully migrated migration branch into main
2 parents 87f1bff + fb1579f commit a48bb6b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

72 files changed

+290
-243
lines changed

.codecov.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
coverage:
22
status:
3-
project: # more options at https://docs.codecov.com/docs/commit-status
3+
project: # more options at https://docs.codecov.com/docs/commit-status
44
default:
55
target: auto # use the coverage from the base commit, fail if coverage is lower
6-
threshold: 0% # allow the coverage to drop by
6+
threshold: 0% # allow the coverage to drop by
77

88
comment:
99
layout: " diff, flags, files"
1010
behavior: default
1111
require_changes: false
12-
require_base: false # [true :: must have a base report to post]
13-
require_head: false # [true :: must have a head report to post]
12+
require_base: false # [true :: must have a base report to post]
13+
require_head: false # [true :: must have a head report to post]
1414
hide_project_coverage: false # [true :: only show coverage on the git diff aka patch coverage]

.flake8

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
# As of now, flake8 does not natively support configuration via pyproject.toml
2+
# https://github.com/microsoft/vscode-flake8/issues/135
13
[flake8]
24
exclude =
35
.git,

.github/ISSUE_TEMPLATE/release_checklist.md

Lines changed: 21 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,30 +6,41 @@ labels: "release"
66
assignees: ""
77
---
88

9-
### PyPI/GitHub release checklist:
9+
### PyPI/GitHub rc-release preparation checklist:
1010

1111
- [ ] All PRs/issues attached to the release are merged.
1212
- [ ] All the badges on the README are passing.
1313
- [ ] License information is verified as correct. If you are unsure, please comment below.
1414
- [ ] Locally rendered documentation contains all appropriate pages, including API references (check no modules are
15-
missing), tutorials, and other human written text is up-to-date with any changes in the code.
16-
- [ ] Installation instructions in the README, documentation and on the website (e.g., diffpy.org) are updated.
15+
missing), tutorials, and other human-written text is up-to-date with any changes in the code.
16+
- [ ] Installation instructions in the README, documentation, and the website are updated.
1717
- [ ] Successfully run any tutorial examples or do functional testing with the latest Python version.
1818
- [ ] Grammar and writing quality are checked (no typos).
19+
- [ ] Install `pip install build twine`, run `python -m build` and `twine check dist/*` to ensure that the package can be built and is correctly formatted for PyPI release.
1920

20-
Please mention @sbillinge here when you are ready for PyPI/GitHub release. Include any additional comments necessary, such as
21-
version information and details about the pre-release here:
21+
Please tag the maintainer (e.g., @username) in the comment here when you are ready for the PyPI/GitHub release. Include any additional comments necessary, such as version information and details about the pre-release here:
2222

23-
### conda-forge release checklist:
23+
### PyPI/GitHub full-release preparation checklist:
2424

25-
<!-- After @sbillinge releases the PyPI package, please check the following when creating a PR for conda-forge release.-->
25+
- [ ] Create a new conda environment and install the rc from PyPI (`pip install <package-name>==??`)
26+
- [ ] License information on PyPI is correct.
27+
- [ ] Docs are deployed successfully to `https://<github-username-or-orgname>/<package-name>`.
28+
- [ ] Successfully run all tests, tutorial examples or do functional testing.
2629

30+
Please let the maintainer know that all checks are done and the package is ready for full release.
31+
32+
### conda-forge release preparation checklist:
33+
34+
<!-- After the maintainer releases the PyPI package, please check the following when creating a PR for conda-forge release.-->
35+
36+
- [ ] Ensure that the full release has appeared on PyPI successfully.
2737
- [ ] New package dependencies listed in `conda.txt` and `test.txt` are added to `meta.yaml` in the feedstock.
28-
- [ ] All relevant issues in the feedstock are addressed in the release PR.
38+
- [ ] Close any open issues on the feedstock. Reach out to the maintainer if you have questions.
39+
- [ ] Tag the maintainer for conda-forge release.
2940

3041
### Post-release checklist
3142

3243
<!-- Before closing this issue, please complete the following: -->
3344

34-
- [ ] Run tutorial examples and conduct functional testing using the installation guide in the README. Attach screenshots/results as comments.
35-
- [ ] Documentation (README, tutorials, API references, and websites) is deployed without broken links or missing figures.
45+
- [ ] Run tutorial examples and conduct functional testing using the installation guide in the README. Attach screenshots/results as comments.
46+
- [ ] Documentation (README, tutorials, API references, and websites) is deployed without broken links or missing figures.
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
### What problem does this PR address?
2+
3+
<!-- Provide a brief overview and link to the issue. Attach outputs, including screenshots (before/after), if helpful for the reviewer. -->
4+
5+
### What should the reviewer(s) do?
6+
7+
<!-- Merge the code, provide feedback, initiate a discussion, etc. -->
8+
9+
<!--
10+
Use the following checklist items when applicable (select only what applies):
11+
- [ ] This PR introduces a public-facing change (e.g., figures, CLI input/output, API).
12+
- [ ] Documentation (e.g., tutorials, examples, README) has been updated.
13+
- [ ] A tracking issue or plan to update documentation exists.
14+
- [ ] This PR affects internal functionality only (no user-facing change).
15+
-->

.github/workflows/build-wheel-release-upload.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,15 @@ on:
44
workflow_dispatch:
55
push:
66
tags:
7-
- '*' # Trigger on all tags initially, but tag and release privilege are verified in _build-wheel-release-upload.yml
7+
- "*" # Trigger on all tags initially, but tag and release privilege are verified in _build-wheel-release-upload.yml
88

99
jobs:
1010
release:
11-
uses: Billingegroup/release-scripts/.github/workflows/_build-wheel-release-upload.yml@v0
11+
uses: scikit-package/release-scripts/.github/workflows/_build-wheel-release-upload.yml@v0
1212
with:
1313
project: diffpy.morph
14-
github_admin_username: sbillinge
15-
14+
c_extension: false
15+
maintainer_GITHUB_username: sbillinge
1616
secrets:
1717
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
1818
PAT_TOKEN: ${{ secrets.PAT_TOKEN }}

.github/workflows/check-news-item.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ name: Check for News
33
on:
44
pull_request_target:
55
branches:
6-
- main
6+
- main
77

88
jobs:
99
check-news-item:
10-
uses: Billingegroup/release-scripts/.github/workflows/_check-news-item.yml@v0
10+
uses: scikit-package/release-scripts/.github/workflows/_check-news-item.yml@v0
1111
with:
1212
project: diffpy.morph

.github/workflows/matrix-and-codecov-on-merge-to-main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ on:
1212

1313
jobs:
1414
matrix-coverage:
15-
uses: Billingegroup/release-scripts/.github/workflows/_matrix-and-codecov-on-merge-to-main.yml@v0
15+
uses: scikit-package/release-scripts/.github/workflows/_matrix-and-codecov-on-merge-to-main.yml@v0
1616
with:
1717
project: diffpy.morph
1818
c_extension: false
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
name: Deploy Documentation on Release
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
docs:
8+
uses: scikit-package/release-scripts/.github/workflows/_publish-docs-on-release.yml@v0
9+
with:
10+
project: diffpy.morph
11+
c_extension: false
12+
headless: false

.github/workflows/tests-on-pr.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,12 @@
11
name: Tests on PR
22

33
on:
4-
push:
5-
branches:
6-
- main
74
pull_request:
85
workflow_dispatch:
96

107
jobs:
118
tests-on-pr:
12-
uses: Billingegroup/release-scripts/.github/workflows/_tests-on-pr.yml@v0
9+
uses: scikit-package/release-scripts/.github/workflows/_tests-on-pr.yml@v0
1310
with:
1411
project: diffpy.morph
1512
c_extension: false

.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/

.isort.cfg

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
[settings]
2+
# Keep import statement below line_length character limit
23
line_length = 79
34
multi_line_output = 3
45
include_trailing_comma = True

.pre-commit-config.yaml

Lines changed: 26 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
default_language_version:
2-
python: python3
2+
python: python3
33
ci:
4-
autofix_commit_msg: |
5-
[pre-commit.ci] auto fixes from pre-commit hooks
6-
autofix_prs: true
7-
autoupdate_branch: 'pre-commit-autoupdate'
8-
autoupdate_commit_msg: '[pre-commit.ci] pre-commit autoupdate'
9-
autoupdate_schedule: monthly
10-
skip: [no-commit-to-branch]
11-
submodules: false
4+
autofix_commit_msg: |
5+
[pre-commit.ci] auto fixes from pre-commit hooks
6+
autofix_prs: true
7+
autoupdate_branch: "pre-commit-autoupdate"
8+
autoupdate_commit_msg: "[pre-commit.ci] pre-commit autoupdate"
9+
autoupdate_schedule: monthly
10+
skip: [no-commit-to-branch]
11+
submodules: false
1212
repos:
1313
- repo: https://github.com/pre-commit/pre-commit-hooks
1414
rev: v4.6.0
@@ -47,6 +47,20 @@ repos:
4747
- repo: https://github.com/codespell-project/codespell
4848
rev: v2.3.0
4949
hooks:
50-
- id: codespell
51-
additional_dependencies:
52-
- tomli
50+
- id: codespell
51+
additional_dependencies:
52+
- tomli
53+
# prettier - multi formatter for .json, .yml, and .md files
54+
- repo: https://github.com/pre-commit/mirrors-prettier
55+
rev: f12edd9c7be1c20cfa42420fd0e6df71e42b51ea # frozen: v4.0.0-alpha.8
56+
hooks:
57+
- id: prettier
58+
additional_dependencies:
59+
- "prettier@^3.2.4"
60+
# docformatter - PEP 257 compliant docstring formatter
61+
- repo: https://github.com/s-weigand/docformatter
62+
rev: 5757c5190d95e5449f102ace83df92e7d3b06c6c
63+
hooks:
64+
- id: docformatter
65+
additional_dependencies: [tomli]
66+
args: [--in-place, --config, ./pyproject.toml]

.readthedocs.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
version: 2
2+
3+
build:
4+
os: "ubuntu-22.04"
5+
tools:
6+
python: "latest"
7+
8+
python:
9+
install:
10+
- requirements: requirements/docs.txt
11+
12+
sphinx:
13+
configuration: doc/source/conf.py

AUTHORS.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
Authors
2-
========
2+
=======
33

44
Billinge Group and community contributors.
55

CHANGELOG.rst

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

55
.. current developments

CODE_OF_CONDUCT.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ Our Pledge
88
We as members, contributors, and leaders pledge to make participation in our
99
community a harassment-free experience for everyone, regardless of age, body
1010
size, visible or invisible disability, ethnicity, sex characteristics, gender
11-
identity and expression, level of experience, education, socio-economic status,
11+
identity and expression, level of experience, education, socioeconomic status,
1212
nationality, personal appearance, race, caste, color, religion, or sexual
1313
identity and orientation.
1414

LICENSE.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
BSD 3-Clause License
22

3-
Copyright (c) 2024, The Trustees of Columbia University
4-
in the City of New York.
3+
Copyright (c) 2024-2025, The Trustees of Columbia University in the City of New York.
54
All rights reserved.
65

76
Redistribution and use in source and binary forms, with or without

README.rst

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,14 @@
1-
|Icon| `diffpy.morph <https://diffpy.github.io/diffpy.morph>`_
2-
==============================================================
1+
|Icon| |title|_
2+
===============
3+
4+
.. |title| replace:: diffpy.morph
5+
.. _title: https://diffpy.github.io/diffpy.morph
36

47
.. |Icon| image:: https://avatars.githubusercontent.com/diffpy
58
:target: https://diffpy.github.io/diffpy.morph
69
:height: 100px
710

8-
|PyPi| |Forge| |PythonVersion| |PR|
11+
|PyPI| |Forge| |PythonVersion| |PR|
912

1013
|CI| |Codecov| |Black| |Tracking|
1114

@@ -23,7 +26,7 @@
2326

2427
.. |PR| image:: https://img.shields.io/badge/PR-Welcome-29ab47ff
2528

26-
.. |PyPi| image:: https://img.shields.io/pypi/v/diffpy.morph
29+
.. |PyPI| image:: https://img.shields.io/pypi/v/diffpy.morph
2730
:target: https://pypi.org/project/diffpy.morph/
2831

2932
.. |PythonVersion| image:: https://img.shields.io/pypi/pyversions/diffpy.morph
@@ -32,7 +35,7 @@
3235
.. |Tracking| image:: https://img.shields.io/badge/issue_tracking-github-blue
3336
:target: https://github.com/diffpy/diffpy.morph/issues
3437

35-
Tools for manipulating and comparing PDF profiles
38+
Python package for manipulating and comparing PDF profiles
3639

3740
``diffpy.morph`` is a Python software package designed to increase the insight
3841
researchers can obtain from measured atomic pair distribution functions
@@ -107,11 +110,11 @@ The following creates and activates a new environment named ``diffpy.morph_env``
107110
conda create -n diffpy.morph_env diffpy.morph
108111
conda activate diffpy.morph_env
109112

110-
To confirm that the installation was successful, type::
113+
To confirm that the installation was successful, type ::
111114

112115
python -c "import diffpy.morph; print(diffpy.morph.__version__)"
113116

114-
The output should print the latest version displayed on the badges above.
117+
The output should print the latest version displayed on the badges above.
115118

116119
If the above does not work, you can use ``pip`` to download and install the latest release from
117120
`Python Package Index <https://pypi.python.org>`_.
@@ -174,7 +177,7 @@ in a development mode, with its sources being directly used by Python
174177
rather than copied to a package directory, use the following in the root
175178
directory ::
176179

177-
pip install -e .
180+
pip install -e .
178181

179182
To ensure code quality and to prevent accidental commits into the default branch, please set up the use of our pre-commit
180183
hooks.
@@ -195,4 +198,9 @@ Before contributing, please read our `Code of Conduct <https://github.com/diffpy
195198
Contact
196199
-------
197200

198-
For more information on diffpy.morph please visit the project `web-page <https://diffpy.github.io/>`_ or email Prof. Simon Billinge at [email protected].
201+
For more information on diffpy.morph please visit the project `web-page <https://diffpy.github.io/>`_ or email Simon J.L. Billinge group at [email protected].
202+
203+
Acknowledgements
204+
----------------
205+
206+
``diffpy.morph`` is built and maintained with `scikit-package <https://scikit-package.github.io/scikit-package/>`_.

doc/manual/images/morph_ex1.png

-254 KB
Loading

doc/manual/images/nacl_example.agr

-623 KB
Binary file not shown.

doc/manual/images/nacl_example.png

114 KB
Loading

doc/manual/images/nacl_example.xcf

-1.15 MB
Binary file not shown.

doc/manual/pdfmorph.pdf

-336 KB
Binary file not shown.

0 commit comments

Comments
 (0)