Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

9
  • How do I make this prompt for the filename (so I don't have to hardcode /tmp/tmux)? Commented Oct 19, 2018 at 8:06
  • @PeeyushKushwaha sorry but my tmux fu is not that good, I'd have to google, let me know if you find it out. Commented Oct 19, 2018 at 8:08
  • 1
    take it further and embed the vim command within the tmux binding and automate a backwards search from the bottom of the file for the last shell prompt to jump back to the last command: bind-key V 'capture-pane' \; capture-pane -S - \; save-buffer /tmp/tmux \; delete-buffer \; send-keys Escape 'ivim "+normal G" +"?^> " /tmp/tmux' Enter. here, PS1 is > . note the trailing space, as well as the i before vim to enter insert mode where the shell is using vi bindings. change according to your needs.
    – pkfm
    Commented Sep 25, 2020 at 8:06
  • @pkfm good tip! Added! Commented Sep 25, 2020 at 8:37
  • This bind-key / copy-mode \; send-key ? did not work for me. It did enter copy mode but did not start a search.
    – SFbay007
    Commented Mar 1, 2021 at 13:24