Skip to content

Commit 47bf79c

Browse files
committed
initial commit
0 parents  commit 47bf79c

32 files changed

+3120
-0
lines changed

.codecov.yml

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# show coverage in CI status, not as a comment.
2+
comment: off
3+
coverage:
4+
status:
5+
project:
6+
default:
7+
target: auto
8+
patch:
9+
default:
10+
target: auto

.coveragerc

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
[run]
2+
source =
3+
mscales
4+
[report]
5+
omit =
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

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
[flake8]
2+
exclude =
3+
.git,
4+
__pycache__,
5+
build,
6+
dist,
7+
versioneer.py,
8+
mscales/_version.py,
9+
docs/source/conf.py
10+
max-line-length = 115
11+
ignore = E203, W503 # Ignore some style 'errors' produced while formatting by 'black'

.gitattributes

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
mscales/_version.py export-subst

.gitignore

+82
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
# Byte-compiled / optimized / DLL files
2+
__pycache__/
3+
*.py[cod]
4+
*$py.class
5+
6+
# C extensions
7+
*.so
8+
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/
25+
.installed.cfg
26+
*.egg
27+
28+
# PyInstaller
29+
# Usually these files are written by a python script from a template
30+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
31+
*.manifest
32+
*.spec
33+
34+
# Installer logs
35+
pip-log.txt
36+
pip-delete-this-directory.txt
37+
38+
# Unit test / coverage reports
39+
htmlcov/
40+
.tox/
41+
.coverage
42+
.coverage.*
43+
.cache
44+
nosetests.xml
45+
coverage.xml
46+
*,cover
47+
.hypothesis/
48+
49+
# Translations
50+
*.mo
51+
*.pot
52+
53+
# Django stuff:
54+
*.log
55+
56+
# Sphinx documentation
57+
docs/build/
58+
docs/source/generated/
59+
60+
# pytest
61+
.pytest_cache/
62+
63+
# PyBuilder
64+
target/
65+
66+
# Editor files
67+
#mac
68+
.DS_Store
69+
*~
70+
71+
#vim
72+
*.swp
73+
*.swo
74+
75+
#pycharm
76+
.idea/
77+
78+
#VSCode
79+
.vscode/
80+
81+
#Ipython Notebook
82+
.ipynb_checkpoints

.pre-commit-config.yaml

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
default_language_version:
2+
python: python3
3+
repos:
4+
- repo: https://github.com/ambv/black
5+
rev: stable
6+
hooks:
7+
- id: black
8+
- repo: https://github.com/pre-commit/pre-commit-hooks
9+
rev: v2.0.0
10+
hooks:
11+
- id: flake8
12+
- repo: https://github.com/kynan/nbstripout
13+
rev: 0.3.9
14+
hooks:
15+
- id: nbstripout

.travis.yml

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
language: python
2+
python:
3+
- 3.7
4+
cache:
5+
directories:
6+
- $HOME/.cache/pip
7+
- $HOME/.ccache # https://github.com/travis-ci/travis-ci/issues/5853
8+
9+
install:
10+
# The versions of pip and numpy that come pre-installed are often too old and
11+
# can cause problems. Upgrade them.
12+
- pip install --upgrade pip numpy
13+
# Install this package and the packages listed in requirements.txt.
14+
- pip install .
15+
# Install extra requirements for running tests and building docs.
16+
- pip install -r requirements-dev.txt
17+
18+
script:
19+
- coverage run -m pytest # Run the tests and check for test coverage.
20+
- coverage report -m # Generate test coverage report.
21+
- codecov # Upload the report to codecov.
22+
- flake8 # Enforce code style ('relaxed' line length limit is set in .flake8 config file).
23+
- make -C docs html # Build the documentation.

AUTHORS.rst

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
=======
2+
Credits
3+
=======
4+
5+
Maintainer
6+
----------
7+
8+
* Fabian C. Moss <[email protected]>
9+
10+
Contributors
11+
------------
12+
13+
None yet. Why not be the first? See: CONTRIBUTING.rst

CONTRIBUTING.rst

+104
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
============
2+
Contributing
3+
============
4+
5+
Contributions are welcome, and they are greatly appreciated! Every
6+
little bit helps, and credit will always be given.
7+
8+
You can contribute in many ways:
9+
10+
Types of Contributions
11+
----------------------
12+
13+
Report Bugs
14+
~~~~~~~~~~~
15+
16+
Report bugs at https://github.com/fabianmoss/mscales/issues.
17+
18+
If you are reporting a bug, please include:
19+
20+
* Any details about your local setup that might be helpful in troubleshooting.
21+
* Detailed steps to reproduce the bug.
22+
23+
Fix Bugs
24+
~~~~~~~~
25+
26+
Look through the GitHub issues for bugs. Anything tagged with "bug"
27+
is open to whoever wants to implement it.
28+
29+
Implement Features
30+
~~~~~~~~~~~~~~~~~~
31+
32+
Look through the GitHub issues for features. Anything tagged with "feature"
33+
is open to whoever wants to implement it.
34+
35+
Write Documentation
36+
~~~~~~~~~~~~~~~~~~~
37+
38+
mscales could always use more documentation, whether
39+
as part of the official mscales docs, in docstrings,
40+
or even on the web in blog posts, articles, and such.
41+
42+
Submit Feedback
43+
~~~~~~~~~~~~~~~
44+
45+
The best way to send feedback is to file an issue at https://github.com/fabianmoss/mscales/issues.
46+
47+
If you are proposing a feature:
48+
49+
* Explain in detail how it would work.
50+
* Keep the scope as narrow as possible, to make it easier to implement.
51+
* Remember that this is a volunteer-driven project, and that contributions
52+
are welcome :)
53+
54+
Get Started!
55+
------------
56+
57+
Ready to contribute? Here's how to set up `mscales` for local development.
58+
59+
1. Fork the `mscales` repo on GitHub.
60+
2. Clone your fork locally::
61+
62+
$ git clone [email protected]:your_name_here/mscales.git
63+
64+
3. Install your local copy into a virtualenv. Assuming you have virtualenvwrapper installed, this is how you set up your fork for local development::
65+
66+
$ mkvirtualenv mscales
67+
$ cd mscales/
68+
$ python setup.py develop
69+
70+
4. Create a branch for local development::
71+
72+
$ git checkout -b name-of-your-bugfix-or-feature
73+
74+
Now you can make your changes locally.
75+
76+
5. When you're done making changes, check that your changes pass flake8 and the tests, including testing other Python versions with tox::
77+
78+
$ flake8 mscales tests
79+
$ python setup.py test
80+
$ tox
81+
82+
To get flake8 and tox, just pip install them into your virtualenv.
83+
84+
6. Commit your changes and push your branch to GitHub::
85+
86+
$ git add .
87+
$ git commit -m "Your detailed description of your changes."
88+
$ git push origin name-of-your-bugfix-or-feature
89+
90+
7. Submit a pull request through the GitHub website.
91+
92+
Pull Request Guidelines
93+
-----------------------
94+
95+
Before you submit a pull request, check that it meets these guidelines:
96+
97+
1. The pull request should include tests.
98+
2. If the pull request adds functionality, the docs should be updated. Put
99+
your new functionality into a function with a docstring, and add the
100+
feature to the list in README.rst.
101+
3. The pull request should work for Python 2.7, 3.3, 3.4, 3.5 and for PyPy. Check
102+
https://travis-ci.org/fabianmoss/mscales/pull_requests
103+
and make sure that the tests pass for all supported Python versions.
104+

LICENSE

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
BSD 3-Clause License
2+
3+
Copyright (c) 2022, Fabian C. Moss
4+
All rights reserved.
5+
6+
Redistribution and use in source and binary forms, with or without
7+
modification, are permitted provided that the following conditions are met:
8+
9+
1. Redistributions of source code must retain the above copyright notice, this
10+
list of conditions and the following disclaimer.
11+
12+
2. Redistributions in binary form must reproduce the above copyright notice,
13+
this list of conditions and the following disclaimer in the documentation
14+
and/or other materials provided with the distribution.
15+
16+
3. Neither the name of the copyright holder nor the names of its contributors
17+
may be used to endorse or promote products derived from this software
18+
without specific prior written permission.
19+
20+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22+
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
23+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
24+
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25+
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
26+
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
27+
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
28+
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
29+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

MANIFEST.in

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
include AUTHORS.rst
2+
include CONTRIBUTING.rst
3+
include LICENSE
4+
include README.rst
5+
include requirements.txt
6+
7+
recursive-exclude * __pycache__
8+
recursive-exclude * *.py[co]
9+
10+
recursive-include docs *.rst conf.py Makefile make.bat
11+
12+
include versioneer.py
13+
include mscales/_version.py
14+
15+
# If including data files in the package, add them like:
16+
# include path/to/data_file

README.rst

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
=======
2+
mscales
3+
=======
4+
5+
.. image:: https://img.shields.io/travis/fabianmoss/mscales.svg
6+
:target: https://travis-ci.org/fabianmoss/mscales
7+
8+
.. image:: https://img.shields.io/pypi/v/mscales.svg
9+
:target: https://pypi.python.org/pypi/mscales
10+
11+
12+
Python package to generate and analyze musical scales.
13+
14+
* Free software: 3-clause BSD license
15+
* Documentation: (COMING SOON!) https://fabianmoss.github.io/mscales.
16+
17+
Features
18+
--------
19+
20+
* TODO

docs/Makefile

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Minimal makefile for Sphinx documentation
2+
#
3+
4+
# You can set these variables from the command line.
5+
SPHINXOPTS = "-W" # This flag turns warnings into errors.
6+
SPHINXBUILD = sphinx-build
7+
SPHINXPROJ = PackagingScientificPython
8+
SOURCEDIR = source
9+
BUILDDIR = build
10+
11+
# Put it first so that "make" without argument is like "make help".
12+
help:
13+
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
14+
15+
.PHONY: help Makefile
16+
17+
# Catch-all target: route all unknown targets to Sphinx using the new
18+
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
19+
%: Makefile
20+
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

0 commit comments

Comments
 (0)