Skip to content

Commit

Permalink
updates the software project's scaffold using PyScaffold 4.5
Browse files Browse the repository at this point in the history
  • Loading branch information
johentsch committed Sep 2, 2023
1 parent 5983fb5 commit 1dd3b56
Show file tree
Hide file tree
Showing 14 changed files with 347 additions and 176 deletions.
8 changes: 6 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
__pycache__/*
.cache/*
.*.swp
.ipynb_checkpoints/
*/.ipynb_checkpoints/*
.DS_Store
*.mscx,
*.mscbackup
Expand All @@ -24,6 +24,7 @@ _version.py
.pydevproject
.settings
.idea
.vscode
tags

# Package files
Expand All @@ -35,8 +36,9 @@ tags
# Unittest and coverage
htmlcov/*
.coverage
.coverage.*
.tox
junit.xml
junit*.xml
coverage.xml
.pytest_cache/

Expand All @@ -52,3 +54,5 @@ MANIFEST

# Per-project virtualenvs
.venv*/
.conda*/
.python-version
2 changes: 1 addition & 1 deletion .isort.cfg
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[settings]
known_third_party = bs4,frictionless,git,gitdb,ms3,numpy,pandas,pathos,pkg_resources,pytablewriter,pytest,setuptools,tqdm,typing_extensions,webcolors,yaml
known_third_party = bs4,frictionless,git,gitdb,ms3,numpy,pandas,pathos,pytablewriter,pytest,setuptools,tqdm,typing_extensions,webcolors,yaml
20 changes: 17 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ repos:
rev: v4.4.0
hooks:
- id: trailing-whitespace
- id: check-added-large-files
- id: check-ast
- id: check-json
- id: check-merge-conflict
Expand All @@ -16,9 +17,16 @@ repos:
- id: mixed-line-ending
args: ['--fix=auto'] # replace 'auto' with 'lf' to enforce Linux/Mac line endings or 'crlf' for Windows

## If you want to automatically "modernize" your Python code:
# - repo: https://github.com/asottile/pyupgrade
# rev: v3.7.0
# hooks:
# - id: pyupgrade
# args: ['--py37-plus']

## If you want to avoid flake8 errors due to unused vars or imports:
# - repo: https://github.com/myint/autoflake
# rev: v1.4
# - repo: https://github.com/PyCQA/autoflake
# rev: v2.1.1
# hooks:
# - id: autoflake
# args: [
Expand All @@ -45,7 +53,7 @@ repos:

## If like to embrace black styles even in the docs:
# - repo: https://github.com/asottile/blacken-docs
# rev: v1.12.0
# rev: v1.13.0
# hooks:
# - id: blacken-docs
# additional_dependencies: [black]
Expand All @@ -59,3 +67,9 @@ repos:
- "--per-file-ignores=__init__.py:F401"
## You can add flake8 plugins via `additional_dependencies`:
# additional_dependencies: [flake8-bugbear]

## Check for misspells in documentation files:
# - repo: https://github.com/codespell-project/codespell
# rev: v2.2.5
# hooks:
# - id: codespell
27 changes: 27 additions & 0 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Build documentation in the docs/ directory with Sphinx
sphinx:
configuration: docs/conf.py

# Build documentation with MkDocs
#mkdocs:
# configuration: mkdocs.yml

# Optionally build your docs in additional formats such as PDF
formats:
- pdf

build:
os: ubuntu-22.04
tools:
python: "3.11"

python:
install:
- requirements: docs/requirements.txt
- {path: ., method: pip}
33 changes: 32 additions & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,22 @@
.. |version| image:: https://img.shields.io/pypi/v/ms3?color=%2300
:alt: PyPI

.. These are examples of badges you might want to add to your README:
please update the URLs accordingly
.. image:: https://readthedocs.org/projects/ms3/badge/?version=latest
:alt: ReadTheDocs
:target: https://ms3.readthedocs.io/en/stable/
.. image:: https://img.shields.io/coveralls/github/<USER>/ms3/main.svg
:alt: Coveralls
:target: https://coveralls.io/r/<USER>/ms3
.. image:: https://img.shields.io/pypi/v/ms3.svg
:alt: PyPI-Server
:target: https://pypi.org/project/ms3/
.. image:: https://pepy.tech/badge/ms3/month
:alt: Monthly Downloads
:target: https://pepy.tech/project/ms3
===============================
ms3 - Parsing MuseScore 3 and 4
Expand Down Expand Up @@ -114,11 +130,26 @@ Parsing several corpora
corpora.parse()
.. _pyscaffold-notes:

Making Changes & Contributing
=============================

This project uses `pre-commit`_, please make sure to install it before making any
changes::

cd ms3
pip install -e ".[dev]" # includes "pip install pre-commit"
pre-commit install


Acknowledgements
================

Development of this software tool was supported by the Swiss National Science Foundation within the project “Distant
Listening – The Development of Harmony over Three Centuries (1700–2000)” (Grant no. 182811). This project is being
conducted at the Latour Chair in Digital and Cognitive Musicology, generously funded by Mr. Claude Latour.

The Python package has been set up using `PyScaffold <https://pyscaffold.org/>`__ 3.2.3.
.. image:: https://img.shields.io/badge/-PyScaffold-005CA0?logo=pyscaffold
:alt: Project generated with PyScaffold
:target: https://pyscaffold.org/
2 changes: 1 addition & 1 deletion docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ MODULEDIR = ../src/ms3

# User-friendly check for sphinx-build
ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $?), 1)
$(error The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD environment variable to point to the full path of the '$(SPHINXBUILD)' executable. Alternatively you can add the directory with the executable to your PATH. If you don't have Sphinx installed, grab it from http://sphinx-doc.org/)
$(error "The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD environment variable to point to the full path of the '$(SPHINXBUILD)' executable. Alternatively you can add the directory with the executable to your PATH. If you don't have Sphinx installed, grab it from https://sphinx-doc.org/")
endif

# Internal variables.
Expand Down
Loading

0 comments on commit 1dd3b56

Please sign in to comment.