Skip to content

Commit b1ea58e

Browse files
authored
Merge pull request #1431 from cuthbertLab/modern-install-system
Modern install system
2 parents cf0f74f + f388b1e commit b1ea58e

22 files changed

+108
-417
lines changed

.codeclimate.yml

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

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ __pycache__/
2121

2222
# OSX
2323
.DS_Store
24+
**/.DS_Store
2425

2526
# C extensions
2627
*.so
@@ -40,6 +41,7 @@ develop-eggs
4041
lib
4142
lib64
4243
__pycache__
44+
**/__pycache__
4345
venv
4446

4547
# Installer logs

.gitignore_global

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

CONTRIBUTING.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,17 @@ own projects that import and extend `music21`.
1919
[Code of Conduct](README.md)
2020

2121

22+
## Preparing to Contribute ##
23+
24+
Be sure to install all of the requirements in `requirements_dev.txt` via:
25+
26+
```
27+
pip3 install -r requirements_dev.txt
28+
```
29+
30+
There are several tools needed for fully testing music21 that aren't included
31+
in the standard `requirements.txt`.
32+
2233
## Issue Tickets ##
2334

2435
Please use the provided templates for bug reports or feature proposals. For issues

MANIFEST.in

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

README.md

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
# music21 #
22

3-
music21 -- A Toolkit for Computational Musicology
3+
`music21` -- A Toolkit for Computer-Aided Musical Analysis and
4+
Computational Musicology
45

5-
Copyright © 2006-2022, Michael Scott Asato Cuthbert
6+
Copyright © 2006-2022, [Michael Scott Asato Cuthbert](http://www.trecento.com)
67

78
For more information, visit:
89
https://web.mit.edu/music21
@@ -13,13 +14,13 @@ https://tinyurl.com/m21colab
1314
And to install, see:
1415
https://web.mit.edu/music21/doc/usersGuide/usersGuide_01_installing.html
1516

16-
Music21 runs on Python 3.8+. Use version 4 on Python 2 or Py3.4, version 5
17+
`Music21` runs on Python 3.8+. Use version 4 on Python 2 or Py3.4, version 5
1718
on Py3.5, version 6 on Py3.6, version 7 on Py3.7.
1819

1920
Released under the BSD (3-clause) license. See LICENSE.
2021
Externally provided software (including the MIT licensed Lilypond/MusicXML test Suite) and
2122
music encoding in the corpus may have different licenses and/or copyrights.
22-
A no-corpus version of music21 is available also on GitHub.
23+
A no-corpus version of `music21` is available also on GitHub.
2324

2425
[![Build Status](https://github.com/cuthbertLab/music21/workflows/maincheck/badge.svg)](https://github.com/cuthbertLab/music21)
2526
[![Lint Status](https://github.com/cuthbertLab/music21/workflows/PyLint/badge.svg)](https://github.com/cuthbertLab/music21)
@@ -41,7 +42,7 @@ See: https://groups.google.com/forum/#!forum/music21list
4142

4243
## Community Code of Conduct ##
4344

44-
Music21 encourages contributions, discussions, and usage from all people interested in
45+
`Music21` encourages contributions, discussions, and usage from all people interested in
4546
music and computers. This encouragement extends to all people regardless of (among other aspects)
4647
gender, race, sexual orientation, disability, religion, appearance, veteran status,
4748
gender identity, socioeconomic status, or nationality.
@@ -56,7 +57,15 @@ sometimes make mistakes and will, in general, accept sincere regrets for such ca
5657
Blatant or repeated violations of the code will result in the removal of the
5758
contributor’s participation in the community.
5859

59-
The maintainers of music21 and associated sites will commit themselves to enforcing
60+
The maintainers of `music21` and associated sites will commit themselves to enforcing
6061
this code of conduct. Users who notice violations, including instances of abuse,
6162
harassment, or otherwise unacceptable behavior are requested to contact cuthbert@mit.edu.
6263
Maintainers will respect confidentiality with regard to reports.
64+
65+
## Acknowledgements ##
66+
67+
The development of `music21` has been supported by
68+
the generosity of the Seaver Institute and the
69+
National Endowment for the Humanities. MIT's Music and Theater Arts Section
70+
and the School of Humanities, Arts, and Social Sciences encouraged Cuthbert
71+
in its development.

documentation/source/installing/installLinux.rst

Lines changed: 37 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,27 @@
44
Installing `music21` on GNU/Linux
55
============================================
66

7-
GNU/Linux, FreeBSD, etc. are supported by `music21`. However, by choosing to use
8-
Unix-like systems you should be an advanced user -- the music21list should not
9-
be used for general installation/configuration problems that are specific to
7+
GNU/Linux, FreeBSD, etc. generally work on `music21`. Many people, including
8+
all of the major developers of `music21` run it on various deployed GNU/Linux,
9+
Unix, AWS-Unix, etc. systems throughout the world. However, no system except
10+
recent Mac and Windows OSes are officially supported.
11+
12+
By choosing to use Unix-like systems you should be an advanced user on your
13+
OS, able to deal with the issues of libraries, linkage, external files, etc.
14+
specific to (and different on) each Unix-like system. The music21list should not
15+
be used for installation/configuration problems on
1016
your operating system. Because of the number of different Unix variants, the list
11-
maintainers can only help with `music21`-specific problems post installation or
12-
Mac/PC problems.
17+
maintainers will only entertain `music21`-specific problems on Unix **post**
18+
installation and configuration.
1319

14-
To reiterate: **GNU/Linux is not a system for which support questions will be answered**
20+
To reiterate: **GNU/Linux is not a system for which support
21+
questions will be answered**
1522

1623

1724
Check Your Version of Python
1825
----------------------------------------------
1926

20-
`Music21` requires Python 3.7+.
27+
`Music21` requires Python 3.8+.
2128

2229
To determine the Python version you have installed, open a shell
2330
or terminal and enter the following command-line argument (where "$" is the prompt):
@@ -26,11 +33,11 @@ or terminal and enter the following command-line argument (where "$" is the prom
2633

2734
it should display something like:
2835

29-
Python 3.9.2
36+
Python 3.10.7
3037

31-
if so, you're okay. If not, go to https://www.python.org/downloads/
32-
and download a newer version. Multiple versions of Python can exist
33-
on a single computer without any problems.
38+
if so, you're okay. If not, upgrade your version of Python. This is
39+
often a problem on some AWS configuations, Google Colab, etc.
40+
which do not ship by default with recent versions of Python.
3441

3542

3643
Download `music21`
@@ -41,10 +48,24 @@ Download the newest version with:
4148
pip3 install --upgrade music21
4249

4350

51+
Configure `music21`
52+
----------------------------------------------
53+
Configure music21 with:
54+
55+
python3 -m music21.configure
56+
57+
It is important to put the path to your MusicXML reader during these
58+
prompts. Music21 cannot find where your XML reader (probably MuseScore)
59+
is installed on most Unix/Linux systems. If you do not know about
60+
filepaths and how to find them, you should probably not be using
61+
GNU/Linux, FreeBSD, etc. with `music21`.
62+
63+
4464
After Installation
4565
-------------------------------
4666

47-
After a successful installation, you may proceed to :ref:`Notes <usersGuide_02_notes>` to
67+
After a successful installation, you may proceed to
68+
:ref:`Notes <usersGuide_02_notes>` to
4869
begin using `music21`.
4970

5071

@@ -53,6 +74,7 @@ Installation Help
5374

5475
If you have followed all the instructions and still encounter problems,
5576
start over from scratch and try it again very carefully.
56-
If you still have problems contact an expert in your operating system.
57-
The `music21` staff cannot help with Unix installation problems except
58-
as paid support.
77+
If you still have problems **contact an expert in your operating system**.
78+
79+
The `music21` maintainers cannot help with Unix installation problems except
80+
as paid support. See Consulting in the FAQ for details on paid support.

documentation/source/installing/installMac.rst

Lines changed: 16 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,15 @@ Trust us that it should work.
1313
Downloading Python 3 from python.org
1414
---------------------------------------
1515

16-
Though Macs come with Python, it's a very old version. We recommend
17-
updating that by going to https://www.python.org/downloads and getting
18-
Python 3.9 or later.
16+
Though most Macs come with Python, it's usually a very old version.
17+
We recommend updating that by going to https://www.python.org/downloads
18+
and getting the latest version.
1919

2020
(The `music21` team strongly recommends using the version of
2121
Python 3 from the python.org website and not the Conda version
22-
(or Enthought Canopy) because it is fully compatible with
23-
`matplotlib`. If you have no plans on plotting functions,
22+
(or Enthought Canopy) because music21 is fully compatible with
23+
`matplotlib` on the python.org site.
24+
If you have no plans on plotting functions,
2425
feel free to use any flavor of Python 3.)
2526

2627

@@ -65,7 +66,7 @@ it should display in Terminal something like the following:
6566
.. image:: images/macScreenPythonVersion.*
6667
:width: 650
6768

68-
If it says 3.7 or higher (or possibly a number like 3.9.2), you're okay.
69+
If it says 3.8 or higher (or possibly a number like 3.10.7), you're okay.
6970
If it says 2.7 or 3.4 or something,
7071
go to https://www.python.org/downloads/
7172
and download a newer version. Multiple versions of Python can exist
@@ -88,56 +89,24 @@ Exit python by typing `quit()`.
8889
Starting the Configuration Assistant
8990
-----------------------------------------------------
9091

91-
If you downloaded the `music21` project from Github, the project folder will
92-
contain a script that runs a configuration assistant. Double click on the
93-
installer.command file to start. This should open a Terminal window and run
94-
the Configuration Assistant. As this is a program downloaded from the Internet,
95-
the System will likely warn you about running it. Go ahead and click "Open".
92+
If you only installed the `music21` package with `pip` (for
93+
instance, by running `sudo pip3 install music21`), you should run
94+
the assistant from a command prompt::
9695

97-
More likely, if you only installed the `music21` package with `pip` (for
98-
instance, by running `sudo pip3 install music21`), you may run the Configuration
99-
Assistant from a Python shell after importing `music21`, like this::
96+
python3 -m music21.configure
97+
98+
You can also run the Configuration Assistant from a Python shell
99+
like this::
100100

101101
import music21
102102
music21.configure.run()
103103

104-
Otherwise, you may launch the assistant from a command prompt::
105-
106-
python3 -m music21.configure
107-
108104
After waiting a few moments to load modules, the Configuration Assistant begins.
109105

110106
.. image:: images/macScreenConfigAssistantStart.*
111107
:width: 650
112108

113-
The first option is to install `music21` in its standard location
114-
(see below, The Installation Destination). Enter "y" or "yes", or
115-
press return to accept the default of "yes". If you installed via pip, you
116-
won't be asked this question.
117-
118-
Before installation begins you may be asked for your Mac password. (The cursor
119-
won't move or display any letters when you type in the password. Just rest assured
120-
that the characters are being transmitted).
121-
As Python packages are stored in a System directory, you need to give permission
122-
to write files to that location.
123-
124-
(If you don't get a prompt but instead start getting
125-
a lot of errors, you probably do not have an administrator account on your Mac.
126-
To make yourself one, quit the installation program (just close the window), open
127-
System Preferences from the Apple menu in the upper left corner of your screen, click on
128-
Users and Groups (4th Row). Click on the lock on the lower-left corner -- you'll need
129-
your Mac password. Then click "Allow user to administer this computer". Then
130-
close System Preferences and click the music21 `installer.command` button again and
131-
go back one step.)
132-
133-
During installation, a large amount of text will display showing files being copied.
134-
Sorry about the mess. Just ignore it! It means it's working.
135-
136-
.. image:: images/macScreenConfigAssistantStart.*
137-
:width: 650
138-
139-
After installation the Configuration Assistant will try to
140-
configure your setup. If you have never used `music21` before,
109+
If you have never used `music21` before,
141110
following these prompts is recommended.
142111

143112
Selecting a MusicXML reader is the first step.
@@ -149,7 +118,7 @@ The Configuration Assistant will attempt to find a MusicXML
149118
reader on your system. If it can't find any, you will be asked
150119
to open a URL to download MuseScore, a simple and free
151120
MusicXML reader and easy writer. Installing MuseScore is
152-
recommended for users who do not have Finale, Sibelius, MuseScore,
121+
recommended for users who do not have Finale, Sibelius, Dorico, MuseScore,
153122
or another MusicXML reader.
154123

155124
If one or more MusicXML readers are found, skip ahead to the next instructions.

documentation/source/installing/installWindows.rst

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ is written in and in which you will write your own programs that
1313
use `music21`.
1414

1515
Windows users should download and install Python version
16-
3.8 or higher.
16+
3.10 or higher.
1717

1818
To get Python for Windows, go to https://www.python.org/downloads/
1919
and click on the "Windows installer" link. It is probably the
@@ -37,7 +37,7 @@ typing in "IDLE" or (on Windows Vista and newer) typing
3737
in "IDLE" in the Search Programs list.
3838

3939
The first lines of text displayed will include a version number.
40-
Make sure it begins with 3.7 or higher.
40+
Make sure it begins with 3.10 or higher.
4141

4242
If your version is too old, download a newer version as above.
4343

@@ -66,15 +66,15 @@ Python on your system. Try uninstalling all of them along with `music21`
6666
and then restarting from scratch).
6767

6868
You should then configure `music21` to find your helper programs
69-
such as MuseScore or Finale. In IDLE
70-
type::
69+
such as MuseScore or Finale. In the command prompt, type::
70+
71+
python3 -m music21.configure
72+
73+
Or, in IDLE type::
7174

7275
import music21
7376
music21.configure.run()
7477

75-
or in the command prompt, type::
76-
77-
python3 -m music21.configure
7878

7979
After Installation
8080
-------------------------------

installer.command

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

0 commit comments

Comments
 (0)