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

Add --listen-unsafe=ADDR to allow remote process execution (#3498)

This commit is contained in:
Junegunn Choi
2023-11-05 10:50:11 +09:00
parent 5c3b044740
commit a818653174
5 changed files with 108 additions and 37 deletions

View File

@@ -793,14 +793,19 @@ ncurses finder only after the input stream is complete.
e.g. \fBfzf --multi | fzf --sync\fR
.RE
.TP
.B "--listen[=[ADDR:]PORT]"
.B "--listen[=[ADDR:]PORT]" "--listen-unsafe[=[ADDR:]PORT]"
Start HTTP server and listen on the given address. It allows external processes
to send actions to perform via POST method. If the port number is omitted or
given as 0, fzf will automatically choose a port and export it as
\fBFZF_PORT\fR environment variable to the child processes. If
\fBFZF_API_KEY\fR environment variable is set, the server would require sending
an API key with the same value in the \fBx-api-key\fR HTTP header.
\fBFZF_API_KEY\fR is required for a non-localhost listen address.
to send actions to perform via POST method.
- If the port number is omitted or given as 0, fzf will automatically choose
a port and export it as \fBFZF_PORT\fR environment variable to the child processes
- If \fBFZF_API_KEY\fR environment variable is set, the server would require
sending an API key with the same value in the \fBx-api-key\fR HTTP header
- \fBFZF_API_KEY\fR is required for a non-localhost listen address
- To allow remote process execution, use \fB--listen-unsafe\fR
e.g.
\fB# Start HTTP server on port 6266