Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Dvtm: A dynamic tiling window manager for the terminal (github.com/martanne)
90 points by yagizdegirmenci on April 10, 2021 | hide | past | favorite | 28 comments


If you are unsatisfied with tmux and familiar with vi, something worth considering is using abduco and the built-in terminal emulator of vim. It will you give windows, tabs and mouse integration for free, it's just missing a couple of bindings to spawn terminals like:

  map <silent><C-w>-  :split +term<CR>
  map <silent><C-w>\| :vsplit +term<CR>
  map <silent><C-w>t  :tabnew +term<CR>
and the rest you already know.


Your mappings are for Neovim, not Vim, where :term already splits the window.

Here they are, fixed for Vim:

    nnoremap <silent> <C-w>-  :terminal<CR>
    nnoremap <silent> <C-w>\| :vertical terminal<CR>
    nnoremap <silent> <C-w>t  :tab terminal<CR>


Thanks for the pointer to :split +term - I just dug through all of :help terminal. Apparently this is a feature from Vim 8.1 that I had completely missed!


I skimmed the documentation but wasn’t persuaded that this offers much over how I use TMUX already


Yeah, my first thought too (well, I guess pretty much everyone's). This seems like "tmux, but less" since tmux is much more than a window manager, and tmux is absolutely not some esoteric software: even if you don't use tmux, you probably know, that if this is something you'd want, you'll install tmux. So, what's the point? Codebase being smaller? I absolutely don't care about the codebase of something I'm not writing myself.


tmux is literally the first program I install on a new setup, even before wget.


unless you have to wget your tmux source/package ;)


who said i haven't the tar.gz on a usb stick ready to deploy? :D


Same, but Byobu because it has nice defaults for tmux.


As a 25 year user of GNU screen, can anyone let me know what improvements this would offer me?


dvtm is very much like dwm, both in some superficial details (layouts), and in deeper philosophical ways (very heavy on doing only one thing well). This is good when you want a small well-scoped tool to do one thing in your stack, but does add friction when you just want everything to work because you need to add more parts to do anything; for instance, dvtm explicitly doesn't handle sessions the way tmux or screen would; you're expected to run with something else (probably abduco) for that. This is not a negative, but it is a tradeoff.


I use both gnu screen and dwm as full screen managers. The only exception is vim, where I have a split term: code one side - running program with error output on the other.

If I split the screen anymore it becomes both too fiddly and the panes become too small on my 13" screen. Does anyone use three or more split windows? If so, what's in them?


I can have up to about a dozen on one screen at a time in i3. Granted it's a 1440p ultrawide and some are stacked behind one another. This is of course also a rare occurrence, which indicates I'm trying to work on too much at once.

Usually it's more like 4-8 (4 columns, with columns spot one up one down) depends on what I'm working on at the time but usually at the lower wned of that range.

I'm a DevOps type so it's usually Terraform which could be a mix of working on a module and "main" TF codebase.

One nice thing about my setup is that it gives me 4 side by side 80char wide terminals/vim instances.

Then of course I have 2 other screens for browser/Comms. I just can't work on a single tiny laptop screen don't know how people cope!


> I just can't work on a single tiny laptop screen don't know how people cope!

I'm the opposite, I work exclusively on a laptop without external screen and I never understand people with many windows/panes :)

I try to limit distractions and I can't stand spending time finding the right window to focus. I have a fullscreen IDE (sometimes split vertically), a fullscreen browser, a fullscreen terminal (iTerm) split in 3 panes, and hotkeys to switch instantly from one to the other. I have other hotkeys to focus other programs (Slack, Datagrip)

I don't need to see everything at the same time, that's distracting and I'd rather whatever I'm working on to be fullscreen, I just need everything to be instantly focussable!


For me you're correct -- I too limit distractions but I also literally get tired several times quicker if I have to read / write on a 13" or even MacBook Pro's 15.6" screen.

I have a 27" iMac Pro and I almost never use any splitting -- except for my editor where having 2 panes side by side is very useful and I still get 95 characters per line on each pane.

...Lately however I felt like I need a bit more space so I ordered toughened display stands (both the iMac Pro and my gaming 35" display are 10kg or more) so I can likely move all my web browsing and Slack itself there, side by side, on that second gaming screen. Still not sure how will that turn out though, I might not need it.


I want to concentrate on my code, and only my code. I only split the coding window since an entire line is too long.


I would love to switch from tmux to dvtm + abduco, but dvtm doesn't have 24bit/truecolor support.


Oops, that's a complete deal-breaker.


It would be nice if tabs in all apps and terminals in tmux/screen could be managed by my window manager just as easily as desktop windows.


I recently moved over to i3 (actually it's sway on Wayland, but that's beside the point). Before I completed the move, I anticipated that a tiling window manager like i3 would replace most of my use of tmux, at least for my laptop and desktop where I have a regular graphical interface and I'm not on a server somewhere.

I was right. Haven't reached for tmux even once since I made the switch. And this is coming from someone who spends probably over 70% of his workday in the terminal using tmux. Having the various shortcuts to move between screens work also work for moving between firefox, zoom, etc is incredible. I'm never going back.


This basically is tmux but suckless.


I recently started using `kitty` terminal emulator. It's very fast and fully customisable.


and the first command I run in any new `kitty` window is of course `tmux`.


I get this by default from XMonad though? And I can tile terminals and other things alongside.


It's useful when you're not running under X, or for folks who want to tile terminals but not run a tiling window manager.


dvtm is very good in principle, but in practice its terminal emulation leaves a lot to be desired. I would love to see someone refactor it to use, say, libvterm as the terminal backend.


how does this bring a better or even a different workflow than tmux ?


It's not necessarily better from that perspective; it's a much smaller+simpler tool, and it solves some of the same problems in a different way. But if tmux works for you and you're not on a suckless binge, dvtm probably won't be appealing.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: