Skip to content

Commit 2836264

Browse files
authored
Merge pull request #91 from bobleesj/cookie-recut
Cookiecut (first time)
2 parents 5798f0c + f0debb9 commit 2836264

Some content is hidden

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

59 files changed

+1917
-653
lines changed

.codecov.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ coverage:
1010
status:
1111
patch:
1212
default:
13-
target: '80'
13+
target: '70'
1414
if_no_uploads: error
1515
if_not_found: success
1616
if_ci_failed: failure
@@ -20,12 +20,13 @@ coverage:
2020
target: auto
2121
if_no_uploads: error
2222
if_not_found: success
23-
if_ci_failed: failure
23+
if_ci_failed: error
2424
paths: '!*/tests/.*'
2525

2626
tests:
2727
target: 97.9%
2828
paths: '*/tests/.*'
29+
if_not_found: success
2930

3031
flags:
3132
tests:

.coveragerc

Lines changed: 11 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,13 @@
1-
# Configuration of the coverage.py tool for reporting test coverage.
2-
3-
[report]
4-
# RE patterns for lines to be excluded from consideration.
5-
exclude_lines =
6-
## Have to re-enable the standard pragma
7-
pragma: no cover
8-
## Don't complain if tests don't hit defensive assertion code:
9-
raise AssertionError
10-
raise NotImplementedError
11-
^[ ]*assert False
12-
13-
## Don't complain if non-runnable code isn't run:
14-
^[ ]*@unittest.skip\b
15-
^[ ]{4}unittest.main()
16-
if __name__ == .__main__.:
17-
18-
191
[run]
2+
source =
3+
diffpy.srfit
4+
[report]
205
omit =
21-
## exclude debug.py from codecov report
22-
*/tests/debug.py
6+
*/python?.?/*
7+
*/site-packages/nose/*
8+
# ignore _version.py and versioneer.py
9+
.*version.*
10+
*_version.py
11+
12+
exclude_lines =
13+
if __name__ == '__main__':

.flake8

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,8 @@ exclude =
44
__pycache__,
55
build,
66
dist,
7-
doc/source/conf.py,
8-
*/doc/source/conf.py,
9-
hooks/post_gen_project.py,
10-
*/__init__.py,
11-
*/debug.py
12-
builtins = cookiecutter
7+
doc/source/conf.py
138
max-line-length = 115
14-
# Ignore some style 'errors' produced while formatting by 'black' (see link below)
9+
# Ignore some style 'errors' produced while formatting by 'black'
1510
# https://black.readthedocs.io/en/stable/guides/using_black_with_other_tools.html#labels-why-pycodestyle-warnings
1611
extend-ignore = E203

.gitarchive.cfg

Lines changed: 0 additions & 5 deletions
This file was deleted.

.gitattributes

Lines changed: 0 additions & 7 deletions
This file was deleted.

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

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
name: Check for News
2+
3+
on:
4+
pull_request_target:
5+
branches:
6+
- main
7+
8+
jobs:
9+
build:
10+
uses: Billingegroup/release-scripts/.github/workflows/_check-news-item.yml@v0
11+
with:
12+
project: diffpy.srfit
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
release:
8+
types:
9+
- prereleased
10+
- published
11+
workflow_dispatch:
12+
13+
jobs:
14+
coverage:
15+
uses: Billingegroup/release-scripts/.github/workflows/_matrix-and-codecov-on-merge-to-main.yml@v0
16+
with:
17+
project: diffpy.srfit
18+
c_extension: false
19+
headless: false
20+
secrets:
21+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: Build and Deploy Docs
2+
3+
on:
4+
release:
5+
types:
6+
- published
7+
workflow_dispatch:
8+
9+
jobs:
10+
docs:
11+
uses: Billingegroup/release-scripts/.github/workflows/_publish-docs-on-release.yml@v0
12+
with:
13+
project: diffpy.srfit
14+
c_extension: false

.gitignore

Lines changed: 72 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,99 @@
1+
# Byte-compiled / optimized / DLL files
2+
__pycache__/
13
*.py[cod]
4+
*$py.class
25

36
# C extensions
47
*.so
58

6-
# Packages
7-
*.egg
8-
*.egg-info
9-
dist
10-
build
11-
eggs
12-
parts
13-
bin
14-
var
15-
sdist
16-
temp
17-
develop-eggs
9+
# Distribution / packaging
10+
.Python
11+
env/
12+
build/
13+
develop-eggs/
14+
dist/
15+
downloads/
16+
eggs/
17+
.eggs/
18+
lib/
19+
lib64/
20+
parts/
21+
sdist/
22+
var/
23+
venv/
24+
*.egg-info/
1825
.installed.cfg
19-
lib
20-
lib64
21-
tags
26+
*.egg
27+
bin/
28+
temp/
29+
tags/
2230
errors.err
2331

32+
# PyInstaller
33+
# Usually these files are written by a python script from a template
34+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
35+
*.manifest
36+
*.spec
37+
2438
# Installer logs
2539
pip-log.txt
40+
pip-delete-this-directory.txt
2641
MANIFEST
2742

2843
# Unit test / coverage reports
44+
htmlcov/
45+
.tox/
2946
.coverage
30-
.tox
47+
.coverage.*
48+
.cache
3149
nosetests.xml
50+
coverage.xml
51+
*,cover
52+
.hypothesis/
3253

3354
# Translations
3455
*.mo
56+
*.pot
3557

3658
# Mr Developer
3759
.mr.developer.cfg
3860
.project
3961
.pydevproject
40-
.settings
62+
63+
# Django stuff:
64+
*.log
65+
66+
# Sphinx documentation
67+
docs/build/
68+
docs/source/generated/
69+
70+
# pytest
71+
.pytest_cache/
72+
73+
# PyBuilder
74+
target/
75+
76+
# Editor files
77+
# mac
78+
.DS_Store
79+
*~
80+
81+
# vim
82+
*.swp
83+
*.swo
84+
85+
# pycharm
86+
.idea/
87+
88+
# VSCode
89+
.vscode/
90+
91+
# Ipython Notebook
92+
.ipynb_checkpoints
4193

4294
# version information
4395
setup.cfg
4496
/src/diffpy/*/version.cfg
97+
98+
# Rever
99+
rever/

.idea/.gitignore

Lines changed: 0 additions & 8 deletions
This file was deleted.

.isort.cfg

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
[settings]
2+
line_length = 115
3+
multi_line_output = 3
4+
include_trailing_comma = True

.pre-commit-config.yaml

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,29 @@
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
1515
hooks:
1616
- id: check-yaml
17-
exclude: 'environment.yml'
1817
- id: end-of-file-fixer
1918
- id: trailing-whitespace
20-
exclude: '\.(rst|txt)$'
19+
- id: check-case-conflict
20+
- id: check-merge-conflict
21+
- id: check-toml
22+
- id: check-added-large-files
2123
- repo: https://github.com/psf/black
2224
rev: 24.4.2
2325
hooks:
2426
- id: black
25-
exclude: '.*\.py'
2627
- repo: https://github.com/pycqa/flake8
2728
rev: 7.0.0
2829
hooks:

0 commit comments

Comments
 (0)