nvim-telescope / telescope-fzy-native.nvim

FZY style sorter that is compiled
MIT License
179 stars 8 forks source link

telescope-fzy-native not working on M1 Macs #4

Closed 9710willy closed 3 years ago

9710willy commented 3 years ago

Due to the fact that the submodule does not have a darwin arm64 build, on a Big Sur M1, telescope fzy native won't work out of the box.

I've tried to locally clone (including the submodule), build the submodule so it has a build compatible with the M1 and make my packer get that plugin, but it seems when I call require('telescope').load_extension('fzy_native') it can't find it.

Any ideas how to solve this issue?

Thank you so much!

Conni2461 commented 3 years ago

It can't support arm64 for mac yet because there are not runners. If i recall correctly.

Can't find probably means that the function couldn't load the so which leads to a failure. I think you just need to insert a kev, value pair into a table.

Probably here https://github.com/romgrk/fzy-lua-native/blob/d47db52e8936912e4ea813a4b65ca64922724327/lua/native.lua#L14-L22

depending how your so is named something like this:

  -- if uname -m == 'arm64' = if lib is named like this: `libfzy-darwin-arm64.so`
  ['arm64'] = 'arm64',

I hope something like this works. I don't have a mac so i can't do any testing

clason commented 3 years ago

Fzy-lua-native just added a darwin-arm64 binary (kindly provided by @smolck ❤️ )

@Conni2461 could you bump the version of the dependency to the latest commit to pull that in? This should close the issue.

Conni2461 commented 3 years ago

https://github.com/nvim-telescope/telescope-fzy-native.nvim/commit/7b3d2528102f858036627a68821ccf5fc1d78ce4

There is also a new is_case_sensitive option (default false), but we don't have a interface for it in telescope. So we could think about adding it (at some point).

I hope it just works now for M1 :)

clason commented 3 years ago

7b3d252

Thanks!

There is also a new is_case_sensitive option (default false), but we don't have a interface for it in telescope. So we could think about adding it (at some point).

Let's wait until someone asks for it :) (Otherwise the next request will be for smartcase...)