Closed edi9999 closed 1 year ago
Hello @junegunn ,
I have a usecase where I would like to reopen this issue. My usecase is running some unit test in watch mode and piping it to fzf (this is a custom script that gets a lot of different information).
What I would like to do is that between each run, I would like to reload the data.
Currently, I need to relaunch the script (and the fzf instance) if I want to be able to see results only of the latest test.
I could send a unix signal to fzf to tell it to reload the data.
Hello @junegunn,
I'm pinging you back on this because I can see a pattern in many of my fzf scripts where fetching the data to fzf would take some time (3-10 seconds), and I prefer to have an fzf instance running with the cached data during the download.
What I do is the following :
I would still find it very cool to be able, after the async fetching of data is done, to send a signal to the fzf instance to reload the data from the cache.
Please take a look at #3094.
man fzf
)Info
Problem / Steps to reproduce
This is a bit similar as what is described in https://github.com/junegunn/fzf/issues/1789, so maybe it still does not make sense to handle signals as events.
I use fzf for multiple cases, and in one particular usecase, I am using fzf on some json data that comes from a given file, which contains an array of items.
Since this data takes some time to refresh from its "production" source, I actually use a cached version of the data for the fzf script which is present on my local machine.
However, in parallel, when the script runs, I also do a refresh of the data so that the data is uptodate when I run the script the next time.
Refreshing the data and then running fzf would add some seconds of delay (approximately 5 probably), and since I use that command quite often, I think it makes sense to do both steps in parallel.
Now the problem I have is that quite often, I'm interested in the updated data, and since it doesn't show the uptodate version at first, it means that I usually start the script once and then again because my cached version is too much outdated.
I would find it cool to have the possibility to tell
My current script :
What I would like to have :