Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/1.10-dev' into split-osc-code
Browse files Browse the repository at this point in the history
  • Loading branch information
matthewkaney committed Apr 10, 2024
2 parents 38fcabd + 997e3f7 commit 4691224
Show file tree
Hide file tree
Showing 1,662 changed files with 162,757 additions and 51,402 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/listener-build-linux.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
name: build-listener-linux

on: [push, pull_request]
on:
push:
paths-ignore:
- "**.md"
pull_request:
paths-ignore:
- "**.md"

jobs:
build:
Expand Down
9 changes: 7 additions & 2 deletions .github/workflows/listener-build-macosx.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
name: build-listener-macosx

on: [push, pull_request]
on:
push:
paths-ignore:
- "**.md"
pull_request:
paths-ignore:
- "**.md"

jobs:
build:
Expand Down
9 changes: 7 additions & 2 deletions .github/workflows/listener-build-windows.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
name: build-listener-windows

on: [push, pull_request]
on:
push:
paths-ignore:
- "**.md"
pull_request:
paths-ignore:
- "**.md"

jobs:
build:
Expand Down
11 changes: 6 additions & 5 deletions .github/workflows/nix.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
# A set of CI jobs for checking the Nix flake.

name: "nix"

on:
pull_request:
push:
branches:
- master
paths-ignore:
- "**.md"
pull_request:
paths-ignore:
- "**.md"

jobs:
cancel-previous-runs:
Expand All @@ -31,7 +32,7 @@ jobs:
needs: cancel-previous-runs
strategy:
matrix:
package: [tidal, tidal-link, tidal-listener, tidal-parse]
package: [tidal, tidal-link, tidal-parse]
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
Expand Down
4 changes: 2 additions & 2 deletions BootTidal.hs
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ let only = (hush >>)
resetCycles = streamResetCycles tidal
setCycle = streamSetCycle tidal
setcps = asap . cps
getcps = streamGetcps tidal
getnow = streamGetnow tidal
getcps = streamGetCPS tidal
getnow = streamGetNow tidal
xfade i = transition tidal True (Sound.Tidal.Transition.xfadeIn 4) i
xfadeIn i t = transition tidal True (Sound.Tidal.Transition.xfadeIn t) i
histpan i t = transition tidal True (Sound.Tidal.Transition.histpan t) i
Expand Down
22 changes: 21 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,25 @@
# TidalCycles log of changes

## 1.9.5 - Sashiko

## What's Changed
* avoid loading stream module in other modules, so hint wont crash by @polymorphicengine in https://github.com/tidalcycles/Tidal/pull/1019
* change streamGetnow to factor in the processAhead and also destroy the sessionstate by @polymorphicengine in https://github.com/tidalcycles/Tidal/pull/1025
* fix minor7sharp9 chord (the 9th wasn't sharp) by @cleary in https://github.com/tidalcycles/Tidal/pull/1036
* add metatune param, now against 1.9-dev by @ahihi in https://github.com/tidalcycles/Tidal/pull/1046
* Build fixes for Tidal 1.9 by @mindofmatthew in https://github.com/tidalcycles/Tidal/pull/1052
* Update link 1.9 dev by @yaxu in https://github.com/tidalcycles/Tidal/pull/1058
* More build fixes by @mindofmatthew in https://github.com/tidalcycles/Tidal/pull/1062
* Consolidate site docs into source docs, and some docs editing by @trespaul in https://github.com/tidalcycles/Tidal/pull/1070
* Fix negative numbers not working for boolean euclids by @geikha in https://github.com/tidalcycles/Tidal/pull/1063

## New Contributors
* @ahihi made their first contribution in https://github.com/tidalcycles/Tidal/pull/1046
* @trespaul made their first contribution in https://github.com/tidalcycles/Tidal/pull/1070
* @geikha made their first contribution in https://github.com/tidalcycles/Tidal/pull/1063

**Full Changelog**: https://github.com/tidalcycles/Tidal/compare/v1.9.4...v1.9.5

## 1.9.4 - Stitch

### What's Changed
Expand All @@ -17,7 +37,7 @@

**Full Changelog**: https://github.com/tidalcycles/Tidal/compare/v1.9.3...v1.9.4

### 1.9.3 - Kolam
## 1.9.3 - Kolam

### What's Changed
* fix for squeezejoin by @yaxu in https://github.com/tidalcycles/Tidal/pull/950
Expand Down
50 changes: 41 additions & 9 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@ compiler/interpreter. Some resources for learning Haskell can be found here:
The main repository is maintained on github:
https://github.com/tidalcycles/tidal

**Please note that ongoing development work towards version 2.0 happens on the 'main'
branch. At the time of writing, bugfixes for current releases should target
the '1.9-dev' branch.**
**At the time of writing, current work should target the '1.10-dev' branch. The 2.0-dev branch is for experiments towards version 2.0.**

The SuperDirt repository is here:
https://github.com/musikinformatik/SuperDirt
Expand Down Expand Up @@ -85,11 +83,45 @@ firefox dist/hpc/prof/html/tests/hpc_index.html

To run up your changes locally, install Tidal with `cabal install`. To remove them again and revert to the latest release, run `ghc-pkg unregister tidal-1.0.0` being sure to match up the version numbers. (note that ghc packaging is in a state of flux at the moment - this command might not actually work..)

# A process for making a release
# Making a Release

We haven't documented a clear process for this, but we'd like to
describe how to..
*Note: This may be incomplete—before making a release, it's a good idea to reach out to an existing project maintainer to double-check the process.*

* Share with others for testing
* Tag a release
* Distribute via hackage / stackage
First, you'll need to figure out the new version number. Tidal follows the [Haskell Package Versioning Policy](https://pvp.haskell.org/)—basically, for a given version (e.g. `v1.0.0`), only update the last number if you're releasing a minor, non-breaking change (so a bug fix release might be `v1.0.1`). A major release requires editing the first or second numbers (so a major release that substantially adds or changes functionality might be `v1.1.0`, and a release that rearchitects the fundamentals would be `v2.0.0`). Major releases include those that update dependencies to a new major release. It's also a good idea to do a major release for any bugfixes where performers have started using the "bug" for aesthetics.

## Get Permission
First, you need to do the following:

* Make sure that you have been given Owner permissions on the tidalcycles GitHub organization or the Tidal repository
* If you don't have one, [create a user account on Hackage](https://hackage.haskell.org/users/register-request). You'll also need to send an email to the Hackage Trustees mailing list to get upload permissions (the email you receive when you create your account will have details about this process).
* Make sure that you've been added to the maintainers group for the tidal package on Hackage

## Create a Draft Release in GitHub

* Draft a [new Tidal release](https://github.com/tidalcycles/Tidal/releases)
* The name of the release will be the human-readable nickname (some traditional form of pattern making or something else that strikes your fancy)
* For the tag, you can specify the next version in the form `v0.0.0` and GitHub will automatically tag the most recent commit whenever you publish the release
* The "Generate Release Notes" is an easy way to list all the relevant updates and new contributors. Feel free to edit this further as needed
* **Save this as a draft for now**

## Update the Repository

Push any final changes to the code, updating the following files:
* **[tidal.cabal](https://github.com/tidalcycles/Tidal/blob/1.10-dev/tidal.cabal)**: Change the version field
* **Outdated Dependencies:** Run `cabal update` then `cabal outdated` to determine whether any of Tidal's dependencies are out of date, then update those as well
* **[CHANGELOG.md](https://github.com/tidalcycles/Tidal/blob/1.10-dev/CHANGELOG.md)**: Add your new version at the top (you can copy the release notes from your draft GitHub release)
* **[src/Sound/Tidal/Version.hs](https://github.com/tidalcycles/Tidal/blob/1.10-dev/src/Sound/Tidal/Version.hs)**: Update the version string here too. This is the version that's printed to the console when someone starts Tidal.
* **If any of the other packages (e.g. tidal-link) have changed**: Update the respective **.cabal** files for these packages, and then update dependency information in **tidal.cabal** as needed.

## Test and Package the Repository

* Run `cabal test` to make sure all the tests pass (see above for details).
* Run `cabal haddock` and watch for errors to test that Cabal can generate the documentation for the package.
* Run `cabal check` to check for any errors with the package metadata.
* Run `cabal sdist` to generate an archive for distribution.

## Upload and Test Releases

* [The Hackage upload page](https://hackage.haskell.org/upload) contains instructions and links for uploading a release archive. **Start by uploading a package candidate because a package release can't be changed!**
* To distribute a package candidate for testing, find the download link for the `.tar.gz` bundle on the Hackage page for the package candidate. This candidate version can be installed with the following command: `cabal v1-install [url]` (note that at this time, [the v1 install command is necessary for installing a library from a URL](https://github.com/haskell/cabal/issues/8335)).
* Once everyone is happy with the new version, go ahead and upload the archive as a package release and publish the release on GitHub!
64 changes: 58 additions & 6 deletions src/Sound/Tidal/Chords.hs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,10 @@ import Data.Maybe

import Sound.Tidal.Pattern

-- major chords
-- * Chord definitions

-- ** Major chords

major :: Num a => [a]
major = [0,4,7]
aug :: Num a => [a]
Expand All @@ -45,7 +48,9 @@ major13 :: Num a => [a]
major13 = [0,4,7,11,14,21]
add13 :: Num a => [a]
add13 = [0,4,7,21]
-- dominant chords

-- ** Dominant chords

dom7 :: Num a => [a]
dom7 = [0,4,7,10]
dom9 :: Num a => [a]
Expand All @@ -66,7 +71,9 @@ eleven :: Num a => [a]
eleven = [0,4,7,10,14,17]
thirteen :: Num a => [a]
thirteen = [0,4,7,10,14,17,21]
-- minor chords

-- ** Minor chords

minor :: Num a => [a]
minor = [0,3,7]
diminished :: Num a => [a]
Expand Down Expand Up @@ -97,7 +104,9 @@ minor13 :: Num a => [a]
minor13 = [0,3,7,10,14,17,21]
minorMajor7 :: Num a => [a]
minorMajor7 = [0,3,7,11]
-- other chords

-- ** Other chords

one :: Num a => [a]
one = [0]
five :: Num a => [a]
Expand All @@ -112,7 +121,9 @@ sevenSus4 :: Num a => [a]
sevenSus4 = [0,5,7,10]
nineSus4 :: Num a => [a]
nineSus4 = [0,5,7,10,14]
-- questionable chords

-- ** Questionable chords

sevenFlat10 :: Num a => [a]
sevenFlat10 = [0,4,7,10,15]
nineSharp5 :: Num a => [a]
Expand All @@ -128,6 +139,8 @@ elevenSharp = [0,4,7,10,14,18]
minor11sharp :: Num a => [a]
minor11sharp = [0,3,7,10,14,18]

-- * Chord functions

-- | @chordate cs m n@ selects the @n@th "chord" (a chord is a list of Ints)
-- from a list of chords @cs@ and transposes it by @m@
-- chordate :: Num b => [[b]] -> b -> Int -> [b]
Expand All @@ -140,6 +153,22 @@ minor11sharp = [0,3,7,10,14,18]
-- enchord :: Num a => [[a]] -> Pattern a -> Pattern Int -> Pattern a
-- enchord chords pn pc = flatpat $ (chordate chords) <$> pn <*> pc

{-|
The @chordTable@ function outputs a list of all available chords and their
corresponding notes. For example, its first entry is @("major",[0,4,7])@ which
means that a major triad is formed by the root (0), the major third (4 semitones
above the root), and the perfect fifth (7 semitones above the root).
As the list is big, you can use the function 'chordL'.
If you know the notes from a chord, but can’t find the name of it, you can use this Haskell code to do a reverse look up into the table:
> filter (\(_,x)->x==[0,4,7,10]) chordTable
This will output @[("dom7",[0,4,7,10])]@
(You’ll need to run @import Sound.Tidal.Chords@ before using this function.)
-}
chordTable :: Num a => [(String, [a])]
chordTable = [("major", major),
("maj", major),
Expand Down Expand Up @@ -273,9 +302,31 @@ chordTable = [("major", major),
("m11s", minor11sharp)
]

-- | Look up a specific chord: @chordL "minor7"@ returns @(0>1)|[0,3,7,10]@.
chordL :: Num a => Pattern String -> Pattern [a]
chordL p = (\name -> fromMaybe [] $ lookup name chordTable) <$> p

{-|
Outputs all the available chords:
@
major maj M aug plus sharp5 six 6 sixNine six9 sixby9 6by9 major7 maj7
major9 maj9 add9 major11 maj11 add11 major13 maj13 add13 dom7 dom9 dom11
dom13 sevenFlat5 7f5 sevenSharp5 7s5 sevenFlat9 7f9 nine eleven 11 thirteen 13
minor min m diminished dim minorSharp5 msharp5 mS5 minor6 min6 m6 minorSixNine
minor69 min69 minSixNine m69 mSixNine m6by9 minor7flat5 minor7f5 min7flat5
min7f5 m7flat5 m7f5 minor7 min7 m7 minor7sharp5 minor7s5 min7sharp5 min7s5
m7sharp5 m7s5 minor7flat9 minor7f9 min7flat9 min7f9 m7flat9 m7f9 minor7sharp9
minor7s9 min7sharp9 min7s9 m7sharp9 m7s9 diminished7 dim7 minor9 min9 m9
minor11 min11 m11 minor13 min13 m13 minorMajor7 minMaj7 mmaj7 one 1 five 5
sus2 sus4 sevenSus2 7sus2 sevenSus4 7sus4 nineSus4 ninesus4 9sus4 sevenFlat10
7f10 nineSharp5 9sharp5 9s5 minor9sharp5 minor9s5 min9sharp5 min9s5 m9sharp5
m9s5 sevenSharp5flat9 7s5f9 minor7sharp5flat9 m7sharp5flat9 elevenSharp 11s
minor11sharp m11sharp m11s
@
(You’ll need to run @import Sound.Tidal.Chords@ before using this function.)
-}
chordList :: String
chordList = unwords $ map fst (chordTable :: [(String, [Int])])

Expand Down Expand Up @@ -317,6 +368,7 @@ chordToPatSeq f noteP nameP modsP = uncollect $ do
let ch = map (+ n) (fromMaybe [0] $ lookup name chordTable)
applyModifierPatSeq f (return ch) modsP

-- | turns a given pattern of some Num type, a pattern of chord names and a list of patterns of modifiers into a chord pattern
-- | Turns a given pattern of some 'Num' type, a pattern of chord names, and a
-- list of patterns of modifiers into a chord pattern
chord :: (Num a, Enum a) => Pattern a -> Pattern String -> [Pattern [Modifier]] -> Pattern a
chord = chordToPatSeq id
3 changes: 1 addition & 2 deletions src/Sound/Tidal/Context.hs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import Prelude hiding ((<*), (*>))

import Data.Ratio as C

import Sound.Tidal.Config as C
import Sound.Tidal.Stream as C
import Sound.Tidal.Control as C
import Sound.Tidal.Core as C
import Sound.Tidal.Params as C
Expand All @@ -31,7 +31,6 @@ import Sound.Tidal.Pattern as C
import Sound.Tidal.Scales as C
import Sound.Tidal.Show as C
import Sound.Tidal.Simple as C
import Sound.Tidal.Stream as C
import Sound.Tidal.Transition as C
import Sound.Tidal.UI as C
import Sound.Tidal.Version as C
Loading

0 comments on commit 4691224

Please sign in to comment.