Where to find tunes
Tune collections in ABC notation to import into a card, and how to bring one in.
A card can play a tune the app makes itself: one of its own (see Designs), one it makes up, or one you import. Cardstock doesn’t search other sites for you. Find a tune on a site below and import it, and its notes go into the card, so it travels in the card’s link like everything else.
Tunes are imported in ABC notation, the plain text most online tune collections use. A tune in ABC looks like this:
X:1
T:Twinkle Twinkle
M:4/4
L:1/4
K:C
"C"C C G G|"F"A A "C"G2|"F"F F "C"E E|"G7"D D "C"C2|]
Importing a tune
In the web app:
- Find a tune on one of the sites below and open it.
- Copy its ABC: the text starting with
X:andT:, often under a button or tab called ABC. Or, when the site offers it as a file, copy the address of the.abcfile itself. - In the editor, open Background and music and choose Add music (or the menu on the tune already there), then Import a tune in ABC.
- Paste the ABC or the address, and choose Import it.
- Pick what it’s played on from the tune’s menu. The preview plays it once the card opens.
From the CLI: save the ABC in a file and run
cardstock tune import --file tune.abc, or give the file’s address with
--url. Put the tune it prints in your card’s spec.
Only the first tune in the text is read. The melody, its chords (the names
in quotes, such as "G"), the key, metre and tempo come across, repeats
and first and second endings play as written, and a long tune is cut to its
first part so it fits in a link. Grace notes, ornaments, lyrics and second
voices are left out.
Where to look
| Site | What’s there | How to get the ABC |
|---|---|---|
| The Session | Tens of thousands of folk tunes, some carols, each with settings | Open a tune, pick a setting and copy the ABC shown under it |
| abcnotation.com | A search across many ABC collections | Search, open a result and copy the ABC from its page |
| Nottingham Music Database | Carols, jigs, reels, waltzes and more, in collections by kind | Open a collection, such as Christmas, and copy one tune from X: to its end |
The Nottingham Music Database collections are text files with many tunes in each, so copy the one tune you want rather than its address.
Writing your own
ABC is easy to write by hand. Each line of the tune is notes: C D E F G A B for the octave from middle C, lower case for the octave above, , and
' for an octave lower or higher, a number after a note for a longer one
(C2) and / for a shorter one (C/), z for a rest and | between
bars. L: sets the length of a plain note and K: the key. The
ABC standard has the rest.
Agents
An agent can search one of these sites, copy a tune’s ABC and import it
with cardstock tune import or the editor’s set-tune tool. The
skill tells it how.