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

Ideads, suggestions #14

Open
andreyorst opened this Issue Oct 12, 2018 · 11 comments

Comments

Projects
None yet
2 participants
@andreyorst
Owner

andreyorst commented Oct 12, 2018

Despite the fact that I post updates of fzf.kak at r/kakoune and at Kakoune Discourse Board I want to have a single place where Ideas and suggestions can go, so I could have easy track of them. Ihis issue isn't for feature requests, but for discussion of ideas, and overall suggestions to the plugin. If you know what you want and can describe it well please open feature request.

Ideas

  • mru - most recently used files
    I'm not sure how to implement this yet, since there's no kind of history Kakoune in the current state. Maybe parsing specified shell history file, and modifying built-in :edit to add files to some history file.
  • Symbol search.
    Extension of tag search, but with scopes.
  • Grep buffer filtering.
    Much like builtin grep,but with filtering results by fzf.
  • Add test suite.
@andreyorst

This comment has been minimized.

Owner

andreyorst commented Oct 14, 2018

I've added extended ctags support for all universal-ctags supported languages. I'm not sure if it counts as symbol search, but for now I'll check it as done.

@supermarin

This comment has been minimized.

supermarin commented Dec 11, 2018

Suggestion: please officially support installing without a plugin manager. There's already more than 1 plug-like solution, and the official way isn't bad at all (clone/submodule and 1 line into kakrc).

@andreyorst

This comment has been minimized.

Owner

andreyorst commented Dec 11, 2018

There's already more than 1 plug-like solution

Can you list those? I'd like to look into them

officially support installing without a plugin manager.

You can source needed files manually, and it will be as official way as it can possible be.

@supermarin

This comment has been minimized.

supermarin commented Dec 11, 2018

There's 2 plugs listed on the official site, and there's one pathogen clone.
Of course, each author will make their plugins installable by their plugin manager.
This is not the ideal scenario, because less advanced users will be tempted to have more than 1 plugin manager (because that's what the official installation steps suggest).

I've tried cloning this pluging manually and sourcing it from kakrc, ran into this:
#30
Loading it with kak-plug works well.

@andreyorst

This comment has been minimized.

Owner

andreyorst commented Dec 12, 2018

well one plug is obsoleted because of mine, and pathogen is just automatization of doing what I suggest you to. And plug. kak is also just doing the loading of everything, but in certain order to workaround the issue that there's no way to make dependencies in kakscript. the order is: load the less nested files first.

Of course, each author will make their plugins installable by their plugin manager.
This is not the ideal scenario, because less advanced users will be tempted to have more than 1 plugin manager (because that's what the official installation steps suggest).

No. I didn't written my plugins to be loaded exclusive by my plugin manager. Instead I wrote my plugin manager in a way that it can load any kind of plugin. This particular plugin is split to parts, so user could control what he needs and what he don't. And since plug.kak can load any plugin, why use another plugin manager? If plug.kak isn't capable of something or you feel that it has some bad decisions or lacking features, just let me know.

I've tried cloning this pluging manually and sourcing it from kakrc, ran into this:
#30
Loading it with kak-plug works well.

I'd like to see what code leads to such situation, because plug.kak essentially loads the files with source command.

@andreyorst

This comment has been minimized.

Owner

andreyorst commented Dec 12, 2018

Example of loading without plugin manager:
image

@supermarin

This comment has been minimized.

supermarin commented Dec 12, 2018

Gotcha; there was no way I could've known you need to source all 3 files without reading the source. I've followed the kak-lsp approach, even the kak-plug approach and sourced only the main /rc/fzf.kak file.

It might be helpful to have

  1. installation instructions other than with kak-plug
  2. a simplified way of loading it if possible

Sorry for bloating your issue - I've got it figured out but this might help future users.
Thank you for writing the plugin.

@andreyorst

This comment has been minimized.

Owner

andreyorst commented Dec 12, 2018

Sorry for bloating your issue - I've got it figured out but this might help future users.
Thank you for writing the plugin.

This issue is here exactly for such talks. No problem.

Gotcha; there was no way I could've known you need to source all 3 files without reading the source. I've followed the kak-lsp approach, even the kak-plug approach and sourced only the main /rc/fzf.kak file.

It might be helpful to have

1. installation instructions other than with kak-plug
2. a simplified way of loading it if possible

Yeah, I'll add instructions. I've thought that there are something that describes plugin structure, but I was mistaken. Previously this plugin was just single kak script (a 1640 lines kakscript, mind you), and it was so bloated that I've decided to split it apart in the same way, how I've written powerline.kak plugin. And it has such instructions, so when was rewriting README for fzf.kak I've thought that I've added something like this here too.

About a simplified way of loading. I'm not sure if it is possible. There's a discussion on Kakoune's tracker: mawww/kakoune#2402, but it seems that everyone is fine with what we have already, and more complex mechanics aren't necessary. But this also means that plugins that have submodules can't be loaded in arbitrary way unless we specify some order, like I've did in plug.kak.

@andreyorst

This comment has been minimized.

Owner

andreyorst commented Dec 12, 2018

installation instructions other than with kak-plug

What do you think: fzf.kak#without-plugin-manager?

@supermarin

This comment has been minimized.

supermarin commented Dec 13, 2018

What do you think: fzf.kak#without-plugin-manager?

Looks better! In my opinion, still a lot of lines to add to kakrc. You might want to make fzf.kak an umbrella file and sorce everything from there. Ideally, loading fzf.kak should be a one liner - the same way as loading plug.kak.
For people who want to custom load only a subset of functionalities, you could still provide the option to source modules directly by hand.

In short, manually sourcing rc/fzf.kak should produce the same end result as plug "andreyorst/fzf.kak"

@andreyorst

This comment has been minimized.

Owner

andreyorst commented Dec 13, 2018

You might want to make fzf.kak an umbrella file and sorce everything from there.

Hm. I've didn't thought of it in this way. Although I don't know if kakoune allows sourcing from script with relative paths but I'll check this. From the first view I think this isn't gonna work, but there's might be a way to workaround this.

Ideally, loading fzf.kak should be a one liner - the same way as loading plug.kak.

Ideally Kakoune community should embrace plugin mangers in a way how Vim community does this. In my opinion. This will allow much more complex and versatile plugins to exist without painful installation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment