Customizing tmux status to represent current working directory and files
- by user69397
I've been playing with this for a couple of days, so I'm sure I'm missing something simple. Love tmux. Using it for development and have so many windows I need a better way of distinguishing them in the status bar and in the buffer list. Seeing a list of "bash" and "vim" isn't really helpful at all. And since they're all on the same host - don't care about the hostname right now.
I'd like to show the current working directory, and the file being worked on. For example when I view the list of buffers I currently see:
(0) 0: vim [100x44] (1 panes) "murph"
(1) 1: vim [100x44] (1 panes) "murph"
(2) 2: bash- [100x44] (1 panes) "murph"
(3) 3: bash* [100x44] (1 panes) "murph"
Here's what I'd like to see
0:vim main.py ~/devl/project1
1:vim index.html ~/devl/samples/staticfiles
2:bash ~/devl/sandbox
3:bash ~/.vimrc
I'd like to see similar info in the status bar for each individual window. While I am able to get PWD to show up in the status bar of a window, it's only the working directory from where tmux was launched. This isn't any help as I change directories.
I'm hoping this can be done without a bunch of scripts.
Thanks all.