tidalcycles / vim-tidal

Vim plugin for TidalCycles
MIT License
222 stars 56 forks source link

Custom `BootTidal.hs` is ignored #90

Closed rrrnld closed 9 months ago

rrrnld commented 10 months ago

I'd like to customize my BootTidal.hs. I set up vim-tidal globally as a neovim plugin through https://github.com/mitchmindtree/tidalcycles.nix via home-manager (I have also opened an issue in the tidalcycles.nix repo in case the issue is somehow caused there: https://github.com/mitchmindtree/tidalcycles.nix/issues/20)

When opening a directory with a BootTidal.hs, the path seems to be set OK (tested via :echo g:tidal_boot), but the prompt that appears when evaluating the first expression always starts like this:

GHCi, version 9.4.6: https://www.haskell.org/ghc/  :? for help
[TidalCycles version 1.9.4]
Installed in /nix/store/sr8dina38j40bm5fpfd0inljdbafza4y-tidal-1.9.4-data/share/ghc-9.4.6/x86_64-linux-ghc-9.4.6/tidal-1.9.4
Listening for external controls on 127.0.0.1:6010
Connected to SuperDirt.
Loaded GHCi configuration from /nix/store/zlxa2pk4kizcwp81a61c7vk5zrvmbx1c-source/BootTidal.hs
tidal> d1 $s "bd"

This happens regardless of whether I use the BootTidal.hs discovery via directory traversal, open neovim via nvim --cmd ':let g:tidal_boot="/path/to/custom/BootTidal.hs"' test.tidal, via nvim +':let g:tidal_boot="/path/to/custom/BootTidal.hs"' test.tidal or export TIDAL_BOOTH_PATH=…. Am I missing something?

Thanks for any help!

rrrnld commented 9 months ago

@mitchmindtree from what i can see you added the feature. do you have any thoughts on this?

mitchmindtree commented 9 months ago

I'm not too sure off the top of my head :thinking:

To help debug, could you try running Vim with the plugin (as opposed to neovim) and report back?

I'm a little less familiar with neovim - were you able to add the regular vim-tidal vim plugin exposed by tidalcycles.nix as a plugin for your neovim?

Could you also echo g:tidal_ghci? It should be the expansion of this: https://github.com/mitchmindtree/tidalcycles.nix/blob/1b1c4df5303e07930d23e8361ab8253ebec0c7bb/flake.nix#L130

rrrnld commented 9 months ago

I've tried to reproduce this with https://github.com/heyarne/vim-tidal-repro, but failed. Neovim and vim built using the flake in that repository both work fine. I therefore think this is not an issue of the vim-plugin, and will be moving to https://github.com/mitchmindtree/tidalcycles.nix/issues/20