Skip to content

Commit

Permalink
Fix '--tmux border-native'
Browse files Browse the repository at this point in the history
  • Loading branch information
junegunn committed Jan 4, 2025
1 parent 120cd7f commit 8a71e09
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,11 @@ CHANGELOG
- Actions
- `change-input-label`
- `transform-input-label`
- Added `--preview-border[=STYLE]` as short for `--preview-window=border-[STYLE]`
- Added `--preview-border[=STYLE]` as short for `--preview-window=border[-STYLE]`
- You can specify `border-native` to `--tmux` so that native tmux border is used instead of `--border`. This can be useful if you start a different program from inside the popup.
```sh
fzf --tmux border-native --bind 'enter:execute:less {}'
```
- Added `toggle-multi-line` action
- Added `toggle-hscroll` action

Expand Down
7 changes: 6 additions & 1 deletion src/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,12 @@ func parseTmuxOptions(arg string, index int) (*tmuxOptions, error) {
}

// Defaults to 'center'
switch tokens[0] {
first := "center"
if len(tokens) > 0 {
first = tokens[0]
}

switch first {
case "top", "up":
opts.position = posUp
opts.width = sizeSpec{100, true}
Expand Down

0 comments on commit 8a71e09

Please sign in to comment.