Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a Nix Flake for building and developing Tidal #963

Merged
merged 1 commit into from
Nov 8, 2022

Conversation

mitchmindtree
Copy link
Contributor

Hi folks! I've been digging into the Tidal code-base lately and thought I'd share the Nix flake I've been using to setup my Tidal environment and enable reproducible builds.

The following is from the flake's description:

This adds a Nix flake for building and developing Tidal.

Packages are included for:

  • tidal
  • tidal-link
  • tidal-listener
  • tidal-parse

A tidal-ghci package is also included. This is a small script that starts an instance of GHCi with Tidal installed and with the BootTidal.hs file passed as the -ghci-script.

Packages can be built with nix build .#tidal or ran with nix run .#tidal-ghci.

A devShell is included that provides cabal-install, stack and all other build inputs for the tidal packages above included under a temporary shell. This shell can be entered with nix develop.

Note that flakes are still an experimental feature of Nix! Their UX is such an improvement on the old workflow that I use them exclusively these days.

That said, I'd understand if the preference was to wait until the feature stabilizes in Nix before landing something like this.

Fwiw, I plan to keep using Tidal for the foreseeable future and am happy to help maintain this going forward (I'm also helping maintain vim-tidal).

A workflow has also been added that checks the formatting of the Nix code and checks that each of the packages build on x86 Linux and macOS.

A Nix flake for building and developing Tidal.

Packages are included for:
- tidal
- tidal-link
- tidal-listener
- tidal-parse

A `tidal-ghci` package is also included. This is a small script that
starts an instance of `GHCi` with `Tidal` installed and with the
`BootTidal.hs` file passed as the `-ghci-script`.

Packages can be built with `nix build .#tidal` or ran with `nix run
.#tidal-ghci`.

A `devShell` is included that provides `cabal-install`, `stack` and all
other build inputs for the tidal packages above included under a
temporary shell. This shell can be entered with `nix develop`.
@yaxu yaxu merged commit e63e30d into tidalcycles:main Nov 8, 2022
@yaxu
Copy link
Member

yaxu commented Nov 8, 2022

Thanks for this, I'm not familiar with nix so am not clear what this is, so if you're happy to continue maintaining it that's fine!

@mitchmindtree mitchmindtree deleted the nix-flake branch November 26, 2022 02:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants