Skip to content

Commit c85f4c5

Browse files
chore: change email and instruction (#182)
* chore: change email and instruction * build: replace docformatter with ruff and make auto-fix
1 parent 7fb1e25 commit c85f4c5

33 files changed

Lines changed: 129 additions & 85 deletions

.pre-commit-config.yaml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,9 @@ repos:
5757
- id: prettier
5858
additional_dependencies:
5959
- "prettier@^3.2.4"
60-
# docformatter - PEP 257 compliant docstring formatter
61-
- repo: https://github.com/s-weigand/docformatter
62-
rev: 5757c5190d95e5449f102ace83df92e7d3b06c6c
60+
# ruff - An extremely fast Python linter and code formatter, written in Rust.
61+
- repo: https://github.com/astral-sh/ruff-pre-commit
62+
rev: v0.15.12
6363
hooks:
64-
- id: docformatter
65-
additional_dependencies: [tomli]
66-
args: [--in-place, --config, ./pyproject.toml]
64+
- id: ruff-check
65+
args: [--fix]

CODE-OF-CONDUCT.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ Enforcement
6767

6868
Instances of abusive, harassing, or otherwise unacceptable behavior may be
6969
reported to the community leaders responsible for enforcement at
70-
sb2896@columbia.edu. All complaints will be reviewed and investigated promptly and fairly.
70+
sbillinge@ucsb.edu. All complaints will be reviewed and investigated promptly and fairly.
7171

7272
All community leaders are obligated to respect the privacy and security of the
7373
reporter of any incident.

LICENSE-PDFgui.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ program by citing the following paper in your publication:
2424
For more information please visit the diffpy web-page at
2525
http://www.diffpy.org
2626
or email Luke Granlund at luke.r.granlund@gmail.com, or Prof. Simon
27-
Billinge at sb2896@columbia.edu.
27+
Billinge at sbillinge@ucsb.edu.
2828

2929
Redistribution and use in source and binary forms, with or without
3030
modification, are permitted provided that the following conditions are met:

LICENSE.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ program by citing the following paper in your publication:
1717
For more information please visit the diffpy web-page at
1818
http://www.diffpy.org
1919
or email Luke Granlund at luke.r.granlund@gmail.com, or Prof. Simon
20-
Billinge at sb2896@columbia.edu.
20+
Billinge at sbillinge@ucsb.edu.
2121

2222
Redistribution and use in source and binary forms, with or without
2323
modification, are permitted provided that the following conditions are met:

README.rst

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,9 @@ The following creates and activates a new environment named ``diffpy.srmise_env`
102102
conda create -n diffpy.srmise_env diffpy.srmise
103103
conda activate diffpy.srmise_env
104104

105-
The output should print the latest version displayed on the badges above.
105+
You can also install diffpy.srmise in another activated environment with ::
106+
107+
conda install -c conda-forge diffpy.srmise
106108

107109
If the above does not work, you can use ``pip`` to download and install the latest release from
108110
`Python Package Index <https://pypi.python.org>`_.
@@ -120,6 +122,7 @@ This package also provides command-line utilities. To check the software has bee
120122

121123
diffpy.srmise --version
122124

125+
The output should print the latest version displayed on the badges above.
123126
You can also type the following command to verify the installation. ::
124127

125128
python -c "import diffpy.srmise; print(diffpy.srmise.__version__)"

docs/examples/multimodel-unknown-dG2.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ def run(plot=True):
140140
dG = ms.dgs[np.argmax(cls_probs)]
141141
best_dGs.append(dG)
142142

143-
print("\n--------- Best models for at least one dG ---------" % dG)
143+
print(f"\n--------- Best models for at least one dG: {dG} ---------")
144144
print(" Best dG Model Class Free AIC Prob File")
145145
for dG in best_dGs:
146146

docs/source/license.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ program by citing the following paper in your publication:
2929
For more information please visit the diffpy web-page at
3030
http://www.diffpy.org
3131
or email Luke Granlund at luke.r.granlund@gmail.com, or Prof. Simon
32-
Billinge at sb2896@columbia.edu.
32+
Billinge at sbillinge@ucsb.edu.
3333

3434
Redistribution and use in source and binary forms, with or without
3535
modification, are permitted provided that the following conditions are met:

news/email.rst

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
**Added:**
2+
3+
* No News Added: change email to the right one and add instruction to install in existing env
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+
* <news item>
20+
21+
**Security:**
22+
23+
* <news item>

pyproject.toml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,10 +60,11 @@ exclude-file = ".codespell/ignore_lines.txt"
6060
ignore-words = ".codespell/ignore_words.txt"
6161
skip = "*.cif,*.dat"
6262

63-
[tool.docformatter]
64-
recursive = true
65-
wrap-summaries = 72
66-
wrap-descriptions = 72
63+
[tool.ruff]
64+
line-length = 115
65+
66+
[tool.ruff.lint.pydocstyle]
67+
convention = "numpy"
6768

6869
[tool.black]
6970
line-length = 115

src/diffpy/srmise/__init__.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@
1313
#
1414
##############################################################################
1515
"""Peak extraction and peak fitting tool for atomic pair distribution
16-
functions."""
16+
functions.
17+
"""
1718

1819
# package version
1920
from diffpy.srmise.version import __version__ # noqa

0 commit comments

Comments
 (0)