plugins/tmux-navigator: re-word usage instructions

This commit is contained in:
Matt Sturgeon 2024-11-16 15:51:55 +00:00
parent a52572c060
commit c8267ba395
No known key found for this signature in database
GPG key ID: 4F91844CED1A8299

View file

@ -32,7 +32,34 @@ helpers.vim-plugin.mkVimPlugin {
## Configure tmux
There are two main ways to configure tmux. Either install the `tmuxPlugins.vim-tmux-navigator` plugin or add a snippet to your tmux config:
> [!NOTE]
> There are two main ways to configure tmux.
#### Option 1: using a plugin
You can install the `vim-tmux-navigator` plugin.
If you're using TPM, add this to your tmux config:
```shell
set -g @plugin 'christoomey/vim-tmux-navigator'
```
If you're using nixos or home-manager to manager tmux, you can use the `programs.tmux.plugins` option for this:
```nix
plugins.tmux.plugins = [
pkgs.tmuxPlugins.vim-tmux-navigator
];
```
#### Option 2: manually specify keybindings
Alternatively, you can specify the keybinding in your tmux config.
If you're using nixos or home-manager to manager tmux, you can use the `programs.tmux.extraConfig` option for this.
Example config from the [upstream docs]:
```shell
# Smart pane switching with awareness of vim splits.