m/fzf
1
0
mirror of https://github.com/junegunn/fzf.git synced 2025-11-19 09:03:43 -05:00

Add --listen=HTTP_PORT option to receive actions

Supersedes #2019

See also:
* #1728
* https://github.com/junegunn/fzf.vim/pull/1044
This commit is contained in:
Junegunn Choi
2022-12-18 00:22:15 +09:00
parent 51c518da1e
commit 1ba7484d60
5 changed files with 337 additions and 249 deletions

View File

@@ -721,6 +721,19 @@ ncurses finder only after the input stream is complete.
e.g. \fBfzf --multi | fzf --sync\fR
.RE
.TP
.B "--listen=HTTP_PORT"
Start HTTP server on the given port to receive actions via POST requests.
e.g.
\fB# Start HTTP server on port 6266
fzf --listen 6266
# Send action to the server
curl -XPOST localhost:6266 -d 'reload(seq 100)+change-prompt(hundred> )'
\fR
The port number is exported as \fB$FZF_LISTEN_PORT\fR on the child processes.
.TP
.B "--version"
Display version information and exit