# What is your kakoune stack?

**URL:** <https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130>\
**Category:** Resources\
**Created:** [July 4, 2020, 8:08pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130 "2020-07-04T20:08:57Z")\
**Posts on this page:** 19\
**Page:** 1

<div class="post-metadata">

**Author:** ![scr](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/scr/32/486_2.png) [@scr](https://discuss.kakoune.com/u/scr)\
**Post date:** [July 4, 2020, 8:08pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/1 "2020-07-04T20:08:57Z")

</div>

Since kakoune does one thing and does it well, it is natural to use it with auxiliary tools.  
I would like to start a discussion on what stack do you use with kakoune? what stack your tried and didn’t work, why you use this one and not another one etc…  
Feel free to join your dotfiles 🙂

For the moment I don’t use kak as my main editor, so I just have a vanilla kak with one plugin : kak-lsp who work fine for me. Next step: a multiplexer and a way integrate a REPL !

---

<div class="post-metadata">

**Author:** ![Delapouite](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/delapouite/32/10_2.png) [@Delapouite](https://discuss.kakoune.com/u/Delapouite)\
**Post date:** [July 4, 2020, 8:24pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/2 "2020-07-04T20:24:39Z")

</div>

Here’s the list of (terminal) tools I’m using regularly, often in coordination with Kakoune: [https://github.com/Delapouite/dot-in-the-sky](https://github.com/Delapouite/dot-in-the-sky)

---

<div class="post-metadata">

**Author:** ![robertmeta](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/robertmeta/32/833_2.png) [@robertmeta](https://discuss.kakoune.com/u/robertmeta)\
**Post date:** [July 4, 2020, 11:03pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/3 "2020-07-04T23:03:38Z")

</div>

Holy crap… so much I didn’t know about! Things I started using as soon as I went through your list… so many new toys!

---

<div class="post-metadata">

**Author:** ![alexherbo2](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/alexherbo2/32/1140_2.png) [@alexherbo2](https://discuss.kakoune.com/u/alexherbo2)\
**Post date:** [July 4, 2020, 11:13pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/4 "2020-07-04T23:13:26Z")

</div>

For me, my new tool is [gitui](https://github.com/extrawurst/gitui). 😁

---

<div class="post-metadata">

**Author:** ![duncan](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/duncan/32/95_2.png) [@duncan](https://discuss.kakoune.com/u/duncan)\
**Post date:** [July 5, 2020, 5:44pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/5 "2020-07-05T17:44:28Z")

</div>

[iterm2](https://www.iterm2.com/) and can’t live without [tmux](https://github.com/tmux/tmux/wiki), is where I live.

---

<div class="post-metadata">

**Author:** ![useredsa](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/useredsa/32/419_2.png) [@useredsa](https://discuss.kakoune.com/u/useredsa)\
**Post date:** [July 5, 2020, 7:08pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/6 "2020-07-05T19:08:00Z")

</div>

My stack:

Distro: KUbuntu/Arch  
Window Manager: [Bspwm](https://github.com/baskerville/bspwm), [Sxhkd](https://github.com/baskerville/sxhkd), looking for a bar. I also use tmux when I ssh.  
Terminal Emulator: Kitty/Alacritty  
Shell: I liked xonsh but I decided to stick to POSIX shell.  
Typical programs:

- Files browser: dolphin (KDE’s), although I will probably change it to something faster.
- Editor: Kakoune (obviously 🙂), and once in a few months vscode
- Pdf Viewer: zathura
- Browser: qutebrowser
- Other: Gimp

Typical terminal commands:

- [ag](https://github.com/ggreer/the_silver_searcher)
- [cf-tool](https://github.com/xalanq/cf-tool) (for competing in [codeforces](https://codeforces.com/))
- entr
- git and git-related

For documentation:

- latex
- asciidoctor

---

<div class="post-metadata">

**Author:** ![alexherbo2](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/alexherbo2/32/1140_2.png) [@alexherbo2](https://discuss.kakoune.com/u/alexherbo2)\
**Post date:** [July 6, 2020, 9:16am UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/7 "2020-07-06T09:16:49Z")

</div>

### Applications

- Window manager: [Sway](https://swaywm.org), [Wayfire](https://wayfire.org)
- Terminal: [Alacritty](https://github.com/alacritty/alacritty)
- Shell: [Elvish](https://elv.sh)
- Terminal multiplexer: [tmux](https://github.com/tmux/tmux)
- File explorer: [lf](https://github.com/gokcehan/lf), [Dolphin](https://dolphin.kde.org)
- Fuzzy finder: [fzf](https://github.com/junegunn/fzf)
- Grep: [ripgrep](https://github.com/BurntSushi/ripgrep)
- Find: [fd](https://github.com/sharkdp/fd)
- Web browser: [Chromium](https://chromium.org), [Krabby](https://krabby.netlify.app)
- Plugins: [connect.kak](https://github.com/alexherbo2/connect.kak), [explore.kak](https://github.com/alexherbo2/explore.kak), [terminal-mode.kak](https://github.com/alexherbo2/terminal-mode.kak)

### Editing

I do all my editing in `kak-shell` from [connect.kak](https://github.com/alexherbo2/connect.kak) to manage sessions. It is inspired by [nix-shell](https://nixos.org/nix/manual#sec-nix-shell) from [NixOS](https://nixos.org) and the first menu (when you choose a session) by [3mux](https://github.com/aaronjanse/3mux).

### Window management

[Sway](https://swaywm.org) or [Wayfire](https://wayfire.org), and [terminal-mode.kak](https://github.com/alexherbo2/terminal-mode.kak) to choose the terminal ([tmux](https://github.com/tmux/tmux), graphical or same terminal window).

### Workspace

I use [tmux](https://github.com/tmux/tmux) as a workspace, where each session is a window.

- `[0]` ⇒ Console
- `[1]` ⇒ Editor
- `[2]` ⇒ Scratch

For example in `[0]`, I have a window for the [Rails](https://rubyonrails.org) server and console (two panes in a window), in `[1]` the editor for Rails, and `[2]` a [lf](https://github.com/gokcehan/lf) instance connected to the editor in `[1]`.

When I switch to another project, I keep `[0]`, `[1]` and `[2]` for the same tasks, but switch the view to the appropriate window in each session (what you can see as tabs in a tmux session).

### Searching files

For searching files, `:e`, `:e <directory>` or `:e <a-.>` (to expand to the buffer directory) to search with [fzf](https://github.com/junegunn/fzf) in the same terminal window (see [connect.kak](https://github.com/alexherbo2/connect.kak) and [explore.kak](https://github.com/alexherbo2/explore.kak)).

```kak
map global prompt -docstring 'Expand to the buffer directory' <a-.> '%sh(dirname "$kak_buffile")<a-!>'

```

For searching buffers, `:b` to search with [fzf](https://github.com/junegunn/fzf) (same plugins).

### Exploring files

For exploring files, either [lf](https://github.com/gokcehan/lf) or [Dolphin](https://dolphin.kde.org) with `:lf` and `:dolphin` (from [connect.kak](https://github.com/alexherbo2/connect.kak)); when I click a file, it opens in the client from which `:lf` and `:dolphin` were run.

I mainly use [Dolphin](https://dolphin.kde.org) on foreign code for discovering and clicking around.

About the TUI file explorer, I use [lf](https://github.com/gokcehan/lf) for its client-server architecture and simple interaction with external programs. You don’t have tabs, but you can copy or cut a file from one lf to another lf. lf initializes the server on first launch – all lf are just clients connected to a server. It’s like Kakoune, but automated, and you have a single server. As far as I know, it is the only terminal file manager offering a client-server architecture.

Like Kakoune, it interacts well with external tools, such as [fzf](https://github.com/junegunn/fzf).

**Example** – Jump to location:

```lf
cmd fzf-jump ${{ # [path...]
  # Select a file under the given or current directory:
  path=$(fd . "$@" | fzf --header='Jump to location')
  # Assign the command:
  if test -f "$path"; then
    command=select
  elif test -d "$path"; then
    command=cd
  else
    exit 1
  fi
  # Send the command to the client:
  lf -remote "
    send $id $command $path
  "
}}

map <c-f> fzf-jump

```

[lf documentation](https://godoc.org/github.com/gokcehan/lf)

There is some oddities (`$f`, `$fs` and `$fx` could be unified and support different formats for perfect escaping, instead of relying on a `filesep` option); block strings are not as robust (multiple levels do not work) and flexible than in Kakoune (you don’t have `%arg{n}` to pass values, but typically just do `\"$1\"` of the shell inside double quotes (where inside it’s the lf speak), which is not a perfect forwarding).

I tried other file managers too.

One of the most different is [Broot](https://dystroy.org/broot/). It is like a project drawer (for its tree-style view) with a [fzf](https://github.com/junegunn/fzf) interface. I see it more like a file selector rather than a file explorer.

The author of lf said on [reddit](https://reddit.com/r/linux/comments/55nzvd/lf_a_terminal_file_manager/d8c9v8v/):

> The way I see it, terminal managers are like a normal mode for shell. You can assign keys to your commands and execute them easily instead of typing (as in hitting i to open a file in your pager rather than typing `less <tab>`).

Broot makes fuzzy searching very easy at the expense of making spatial navigation (therefore exploring) not easy.

While lf has —hjkl— spatial navigation, it can extend its functionalities with [fzf](https://github.com/junegunn/fzf) or another program to open a file or navigate into deep structures.

I wish I could make a better use of [Broot](https://dystroy.org/broot/) in my workflow, but I didn’t.

See also the last paragraphs of [Why Kakoune – What is modal text editing](https://kakoune.org/why-kakoune/why-kakoune.html#_what_is_modal_text_editing); I think @mawww better captured what I try to express.

---

<div class="post-metadata">

**Author:** ![robertmeta](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/robertmeta/32/833_2.png) [@robertmeta](https://discuss.kakoune.com/u/robertmeta)\
**Post date:** [July 6, 2020, 11:22am UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/8 "2020-07-06T11:22:15Z")

</div>

> [@useredsa](#):
>
> Terminal Emulator: Kitty/Alacritty

I have read a lot about these “accelerated terminals”, can you actually feel a difference?

---

<div class="post-metadata">

**Author:** ![useredsa](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/useredsa/32/419_2.png) [@useredsa](https://discuss.kakoune.com/u/useredsa)\
**Post date:** [July 6, 2020, 12:08pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/9 "2020-07-06T12:08:53Z")

</div>

> [@robertmeta](#):
>
> I have read a lot about these “accelerated terminals”, can you actually feel a difference?

Well, the experience is not that much different. I used to use `gnome-terminal`, but it wouldn’t even resize to arbitrary sizes. I like kitty’s wide range of features more than anything else.

Regarding speed, a friend of mine recently switched from his default terminal emulator in MacOS to alacritty and he told me he noticed it was much faster. Personally, even if they really are quite faster, I don’t think it is going to impact your workflow that much. I prefer them over `gnome-terminal` or `konsole` though.

---

<div class="post-metadata">

**Author:** ![robertmeta](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/robertmeta/32/833_2.png) [@robertmeta](https://discuss.kakoune.com/u/robertmeta)\
**Post date:** [July 6, 2020, 1:08pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/10 "2020-07-06T13:08:55Z")

</div>

At one point in the recent past, didn’t Alacritty has rather poor meta/alt support?

---

<div class="post-metadata">

**Author:** ![useredsa](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/useredsa/32/419_2.png) [@useredsa](https://discuss.kakoune.com/u/useredsa)\
**Post date:** [July 6, 2020, 3:09pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/11 "2020-07-06T15:09:41Z")

</div>

I don’t know anything about that. I haven’t experienced any issues.

EDIT: my friend told me he had to hardcode some keys in macOS, but he said it was as easy as copying them from a blog. He told me that alacritty is the best option he know for macOS, and that he notices the speed a lot.  
Check [this issue](https://github.com/alacritty/alacritty/issues/2017).

---

<div class="post-metadata">

**Author:** ![prion](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/prion/32/404_2.png) [@prion](https://discuss.kakoune.com/u/prion)\
**Post date:** [July 6, 2020, 11:07pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/12 "2020-07-06T23:07:32Z")

</div>

My understanding is that for things like input delay, start up time etc… they aren’t necessarily any better than the competition but they do have excellent throughput.

---

<div class="post-metadata">

**Author:** ![SolitudeSF](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/solitudesf/32/22_2.png) [@SolitudeSF](https://discuss.kakoune.com/u/SolitudeSF)\
**Post date:** [July 7, 2020, 6:50am UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/13 "2020-07-07T06:50:03Z")

</div>

alacritty has awful input latency because all the developers care about is synthetic throughput benchmarks.

---

<div class="post-metadata">

**Author:** ![schemar](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/schemar/32/502_2.png) [@schemar](https://discuss.kakoune.com/u/schemar)\
**Post date:** [July 7, 2020, 8:46am UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/14 "2020-07-07T08:46:38Z")

</div>

My experience on macOS is that Alacritty was noticeably faster than iTerm2. I still switched back to iTerm2 for two reasons:

1. I want the left and right Option key to behave differently. One shall remain „option“ to easily write special characters like „ü“, the other shall be „alt“ (ESC+) for alt-commands. That’s possible in iTerm, but not in Alacritty.
2. Alacritty doesn’t know the concept of multiple windows. So, for example, for every open Alacritty window you have a separate icon in the dock. They are independent „open programs“ and that bothers me.

---

<div class="post-metadata">

**Author:** ![himi](https://discuss.kakoune.com/letter_avatar_proxy/v4/letter/h/848f3c/32.png) [@himi](https://discuss.kakoune.com/u/himi)\
**Post date:** [July 7, 2020, 3:11pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/15 "2020-07-07T15:11:08Z")

</div>

I started investigating kitty (ratherthan gnome terminal) to try and reduce memory use, and eventually switched over fully because of other features (the flexible startup scripts and the nice windowing support, along with better keyboard usability). I don’t know if it’s been noticeably faster or more responsive, but it certainly hasn’t been /less/ responsive.

---

<div class="post-metadata">

**Author:** ![CochinoChingon](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/cochinochingon/32/609_2.png) [@CochinoChingon](https://discuss.kakoune.com/u/CochinoChingon)\
**Post date:** [July 9, 2020, 7:03am UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/16 "2020-07-09T07:03:00Z")

</div>

have you tried [kitty](https://sw.kovidgoyal.net/kitty/)? I much prefer it over alacritty, plus built in pane creation `<ctrl+enter>` and pane reorganization `<ctrl+L>` tall, stack, horizontal,vertical,fat.

---

<div class="post-metadata">

**Author:** ![robertmeta](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/robertmeta/32/833_2.png) [@robertmeta](https://discuss.kakoune.com/u/robertmeta)\
**Post date:** [July 9, 2020, 4:35pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/17 "2020-07-09T16:35:30Z")

</div>

I am starting to explore kitty – hard transition from tmux. Probably not going to survive it, but interesting.

---

<div class="post-metadata">

**Author:** ![CochinoChingon](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/cochinochingon/32/609_2.png) [@CochinoChingon](https://discuss.kakoune.com/u/CochinoChingon)\
**Post date:** [July 9, 2020, 8:28pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/18 "2020-07-09T20:28:43Z")

</div>

oh I still very much use tmux, particularly for commands that take a few hours/days to complete. Though it’s usually on my server, on my DD just kitty.

---

<div class="post-metadata">

**Author:** ![schemar](https://discuss.kakoune.com/user_avatar/discuss.kakoune.com/schemar/32/502_2.png) [@schemar](https://discuss.kakoune.com/u/schemar)\
**Post date:** [July 10, 2020, 6:18pm UTC](https://discuss.kakoune.com/t/what-is-your-kakoune-stack/1130/19 "2020-07-10T18:18:48Z")

</div>

Hey, yeah I gave it another shot and I think I will switch to kitty for good. While sticking with tmux. Kitty supports everything I need on macOS (e.g one option-key; one alt-key). Plus I now get to share a single, version controlled kitty config across my macOS/Linux systems.

I think I finally may have found my terminal 😊
