Skip to content

Commit

Permalink
Merge branch 'release/v0.3.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
wpk committed May 3, 2023
2 parents c3074e5 + b6a49ac commit 14b0bfc
Show file tree
Hide file tree
Showing 105 changed files with 18,222 additions and 3,452 deletions.
92 changes: 42 additions & 50 deletions .cruft.json
Original file line number Diff line number Diff line change
@@ -1,52 +1,44 @@
{
"template": "https://github.com/wpk-nist-gov/cookiecutter-pypackage.git",
"commit": "be1b9cec709f862f8de5132e517a42db90758f04",
"checkout": "feature/markdown",
"skip": [
"src/thermoextrap/__init__.py",
"environment.yaml",
"HISTORY.md",
"AUTHORS.md",
"MANIFEST.in",
"README.md",
"docs/spelling_wordlist.txt",
"environment/dev-extras.yaml",
"environment/docs-extras.yaml",
"environment/test-extras.yaml",
"docs/index.md",
"docs/installation.md",
".gitignore"
],
"context": {
"cookiecutter": {
"full_name": "William P. Krekelberg",
"email": "[email protected]",
"github_username": "usnistgov",
"pypi_username": "wpk-nist",
"conda_channel": "wpk-nist",
"project_name": "thermoextrap",
"project_slug": "thermoextrap",
"_copy_without_render": [
"*.html",
"docs/_templates/*.rst",
"docs/_templates/autosummary/*.rst",
"docs/_templates/autodocsumm/*.rst",
"docs/_static/*",
"docs/_static/css/*",
"docs/_static/js/*"
],
"project_short_description": "Thermodynamic extrapolation",
"version": "0.0.1",
"use_pytest": "y",
"use_pypi_deployment_with_travis": "n",
"command_line_interface": "No command-line interface",
"create_author_file": "y",
"open_source_license": "NIST license",
"sphinx_auto": "autosummary",
"sphinx_use_autodocsumm": "y",
"sphinx_theme": "sphinx_book_theme",
"_template": "https://github.com/wpk-nist-gov/cookiecutter-pypackage.git"
}
},
"directory": null
"template": "https://github.com/wpk-nist-gov/cookiecutter-pypackage.git",
"commit": "cb20a32f67dadb4142be54898a87de1efdce6bd6",
"checkout": "feature/markdown",
"skip": [
"src/thermoextrap/__init__.py",
"docs/examples/usage/demo.ipynb",
"examples/usage/demo.ipynb",
"docs/examples/example-usage.md"
],
"context": {
"cookiecutter": {
"full_name": "William P. Krekelberg",
"email": "[email protected]",
"github_username": "usnistgov",
"pypi_username": "wpk-nist",
"conda_channel": "wpk-nist",
"project_name": "thermoextrap",
"project_slug": "thermoextrap",
"_copy_without_render": [
"*.html",
"docs/_templates/*.rst",
"docs/_templates/autosummary/*.rst",
"docs/_templates/autodocsumm/*.rst",
"docs/_static/css/*",
"docs/_static/js/*",
"changelog.d/templates/*",
"changelog.d/templates/auto-changlog/*"
],
"project_short_description": "Thermodynamic extrapolation",
"version": "0.0.1",
"use_pytest": "y",
"use_pypi_deployment_with_travis": "n",
"command_line_interface": "No command-line interface",
"create_author_file": "y",
"open_source_license": "NIST license",
"sphinx_auto": "autosummary",
"sphinx_use_autodocsumm": "y",
"sphinx_theme": "sphinx_book_theme",
"_template": "https://github.com/wpk-nist-gov/cookiecutter-pypackage.git"
}
},
"directory": null
}
44 changes: 44 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# http://editorconfig.org

root = true

[*]
indent_style = space
indent_size = 4
trim_trailing_whitespace = true
insert_final_newline = true
charset = utf-8
end_of_line = lf

[*.bat]
indent_style = tab
end_of_line = crlf

[LICENSE]
insert_final_newline = false

[Makefile]
indent_style = tab

[*.mk]
indent_style = tab

[*.{yaml,yml}]
indent_size = 2

[*.ini]
indent_size = 4

[*.json]
indent_size = 2


[*.txt]
indent_size = 4
trim_trailing_whitespace = false


[*.md]
indent_size = 2
max_line_length = 80
trim_trailing_whitespace = false
9 changes: 3 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ env/
build/
develop-eggs/
dist/
dist-conda/
downloads/
eggs/
.eggs/
Expand Down Expand Up @@ -107,9 +106,7 @@ ENV/
pyrightconfig.json
.autoenv.zsh
.autoenv_leave.zsh
/docs/generated/
/docs/**/generated/
/monkeytype.sqlite3
/dist-conda/
/cruft.patch
/docs/jupyter_execute/
/docs/reference/generated/
/dist-conda/*
!/dist-conda/Makefile
6 changes: 6 additions & 0 deletions .markdownlint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Example markdownlint configuration with all properties set to their default value

# Default state for all rules
default: true
# disable rules?
# MD026: false
151 changes: 99 additions & 52 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,86 +3,133 @@
# pre-commit run --all-files
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
default_install_hook_types:
- pre-commit
- commit-msg
repos:
#* Top level
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-added-large-files
- id: check-yaml
# args: [--unsafe]
# Ruff
- id: check-json
- id: check-merge-conflict
- id: check-symlinks
- id: check-toml
#* Formatting
- repo: https://github.com/pre-commit/mirrors-prettier
rev: "v3.0.0-alpha.6"
hooks:
- id: prettier
stages: [commit]
additional_dependencies:
- prettier-plugin-toml
exclude: ^tests/lnpy_data/sample_data.json
#** markdown
- repo: https://github.com/DavidAnson/markdownlint-cli2
rev: v0.6.0
hooks:
- id: markdownlint-cli2
args: ["--style prettier"]
#* Linting
- repo: https://github.com/charliermarsh/ruff-pre-commit
# Ruff version.
rev: 'v0.0.254'
rev: "v0.0.261"
hooks:
- id: ruff
args: ["--fix"]
# isort should run before black as black sometimes tweaks the isort output
- repo: https://github.com/PyCQA/isort
rev: 5.12.0
hooks:
- id: isort
stages: [manual]
# https://github.com/python/black#version-control-integration
- repo: https://github.com/psf/black
rev: 23.1.0
rev: 23.3.0
hooks:
- id: black-jupyter
# - id: black-jupyter
# Move to just black. use nbqa for notebook formatting
- id: black
- repo: https://github.com/adamchainz/blacken-docs
rev: "1.13.0" # replace with latest tag on GitHub
rev: "1.13.0"
hooks:
- id: blacken-docs
additional_dependencies:
- black==23.1.0
- black==23.3.0
exclude: ^README.md
- repo: https://github.com/keewis/blackdoc
rev: v0.3.8
- repo: https://github.com/nbQA-dev/nbQA
rev: 1.7.0
hooks:
- id: blackdoc
additional_dependencies: ["black==23.1.0"]
- id: blackdoc-autoupdate-black
- repo: https://github.com/codespell-project/codespell
rev: v2.2.2
- id: nbqa-ruff
additional_dependencies: [ruff]
- id: nbqa-black
additional_dependencies: [black]

#* Commit message
- repo: https://github.com/commitizen-tools/commitizen
rev: v3.0.1
hooks:
- id: codespell
types_or: [python, rst, markdown, cython, c]
additional_dependencies: [tomli]
args: [-I, docs/spelling_wordlist.txt]
- id: commitizen
stages: [commit-msg]

#* Manual Linting
- repo: local
hooks:
- id: mypy
name: mypy
entry: tox
args: ["-e", "lint-mypy"]
language: system
pass_filenames: false
# additional_dependencies: [tox]
types: [python]
require_serial: true
stages: [manual]
# this should be run before flake8 to
# this should be run externally
# messes up too many things
# - repo: https://github.com/PyCQA/docformatter
# rev: v1.5.0
# hooks:
# - id: docformatter
# args: [--in-place]
- id: pyright
name: pyright
entry: pyright
args: []
language: system
pass_filenames: true
# additional_dependencies: [tox]
types: [python]
require_serial: true
stages: [manual]
# isort, pyupgrade, flake8 defer to ruff
- repo: https://github.com/PyCQA/isort
rev: 5.12.0
hooks:
- id: isort
stages: [manual]
- repo: https://github.com/asottile/pyupgrade
rev: v3.3.1
hooks:
- id: pyupgrade
stages: [manual]
args: [--py38-plus]
- repo: https://github.com/pycqa/flake8
rev: 6.0.0
hooks:
- id: flake8
stages: [manual]
additional_dependencies: [flake8-docstrings]
exclude: ^tests/|examples/gpr_active_learning/|src/thermoextrap/legacy/|^docs/conf.py|^setup.py
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.1.1
additional_dependencies:
- flake8-docstrings
- Flake8-pyproject
# - pep8-naming
# - flake8-rst-docstrings
exclude: ^tests/|^src/thermoextrap/tests/|^docs/conf.py|^setup.py|example/gpr_active_learning/|src/thermoextrap/legacy
- repo: https://github.com/nbQA-dev/nbQA
rev: 1.7.0
hooks:
- id: mypy
# `properies` & `asv_bench` are copied from setup.cfg.
# `_typed_ops.py` is added since otherwise mypy will complain (but notably only in pre-commit)
exclude: properties|asv_bench|_typed_ops.py|conf.py
# This is slow and so we take it out of the fast-path; requires passing
# `--hook-stage manual` to pre-commit
- id: nbqa-pyupgrade
additional_dependencies: [pyupgrade]
stages: [manual]
additional_dependencies: [types-pkg_resources, typing-extensions==3.10.0.0, numpy]
- repo: https://github.com/asottile/pyupgrade
rev: v3.3.1
args: [--py38-plus]
- id: nbqa-isort
additional_dependencies: [isort]
stages: [manual]
#** spelling
- repo: https://github.com/codespell-project/codespell
rev: v2.2.4
hooks:
- id: pyupgrade
- id: codespell
types_or: [python, rst, markdown, cython, c]
additional_dependencies: [tomli]
args: [-I, docs/spelling_wordlist.txt]
stages: [manual]
args:
- --py38-plus
# remove on f-strings in Py3.7
- --keep-percent-format
1 change: 1 addition & 0 deletions .prettierrc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
proseWrap: "always"
Loading

0 comments on commit 14b0bfc

Please sign in to comment.