Omit port number in --listen for automatic port assignment

Close #3200
This commit is contained in:
Junegunn Choi
2023-03-19 15:42:47 +09:00
parent 3c34dd8275
commit fcd7e8768d
6 changed files with 77 additions and 24 deletions

View File

@@ -1,6 +1,20 @@
CHANGELOG
=========
0.39.0
------
- If you use `--listen` option without a port number fzf will automatically
allocate an available port and export it as `$FZF_PORT` environment
variable.
```sh
# Automatic port assignment
fzf --listen --bind 'start:execute-silent:echo $FZF_PORT > /tmp/fzf-port'
# Say hello
curl "localhost:$(cat /tmp/fzf-port)" -d 'preview:echo Hello, fzf is listening on $FZF_PORT.'
```
- Bug fixes
0.38.0
------
- New actions