The executable file alda
in the bin
directory of this repository is a standalone executable script that can be run from anywhere. It will retrieve the latest release version of Alda and run it, passing along any command-line arguments you give it.
-
To install Alda, simply copy the
alda
script from this repo into any directory in your$PATH
, e.g./bin
or/usr/local/bin
:curl https://raw.githubusercontent.com/alda-lang/alda/master/bin/alda -o /usr/local/bin/alda && chmod +x /usr/local/bin/alda
-
This script requires the Clojure build tool Boot, so you will need to have that installed as well. Mac OS X users with Homebrew can run
brew install boot-clj
to install Boot. Otherwise, see here for more details about installing Boot.
Once you've completed the steps above, you'll be able to run alda
from any working directory. Running the command alda
by itself will display the help text.
Alda comes in two pieces: the Alda library (the part that does all the work) and the alda
start script.
The start script will rarely need to be updated, but if you ever do need to get the latest version, you can do so by running the following command:
alda script > /usr/local/bin/alda
The Alda library will keep itself updated on your computer each time you run it.
The alda
script doesn't seem to work for Windows users. If you're a Windows power user, please feel free to weigh in on this issue. Until we have that sorted out, there is a workaround:
- Install Boot.
- Clone this repo and
cd
into it. - You can now run
boot alda -x "<cmd> <args>"
while you are in this directory.
Examples:
boot alda -x repl
to start the Alda REPLboot alda -x "play --code 'piano: c d e f g'"
Caveats:
- It's more typing.
- It only works if you're in the Alda repo folder.
- Unlike the
alda
script, running theboot alda
task will not automatically update Alda; you will have to do so manually by runninggit pull
. - If the command you're running is longer than one word, you must wrap it in double quotes -- see the examples above.
For the best experience when editing Alda score files, install the Alda file-type plugin for your editor of choice.
Don't see a plugin for your favorite editor? Write your own and add it here! :)