

If you happen to run into issues with rbenv you can set a specific version to use with the “pre_window:” setting. An example file can be seen in this section of the documentation. There are many configuration options available when using tmuxinator to generate a new project file.
Tmux iterm panes windows#
This gem allows for project specific YAML files to be created that not only allow for the configuration of the tmux windows and panes but also allow commands to be run in them on start up and shut down. Tmuxinator is a ruby gem that elevates using tmux for project development from a good experience to a fantastic experience. Going through the process of starting tmux, opening panes and windows and spinning up the processes I used frequently in their respective places was getting to be too much.

I had moved to using Vim (now Neovim) in the terminal for all of my editing and at the time I was developing a couple of Rails projects.

Now, spinning up a tmux session from scratch every time I wanted to work on something was fine if I was working on a remote server doing patches or troubleshooting an issue, but when developing locally it was starting to get a little tiresome. With the added ability to ssh into a server and reattach to the session it was an amazing experience. Spinning up a tmux session and having the ability to split screens for editing, running commands, tailing logs and more at the touch of a couple of keys was immensely empowering and changed the way that I used the terminal substantially. Out of the box the controls felt more intuitive and once the default leader key combination is switched from CTRL-b to something more sensible ( CTRL-s or CTRL-a) it is a joy to use. The configuration of tmux is what originally brought me to make the switch. The tmux project is a successor to screen that allows for easier configuration while containing most of the major features of Screen. I used Screen for a little while until I learned about tmux. You can also reattach to the screen session after logging back into the server. Screen allows for terminal multiplexing that is disconnected from the user’s session, useful for unreliable network connections as the running commands will not be terminated if the session is ended. I believe that these tools can help anyone that uses the terminal be more productive and, more importantly, happier. With the help of tmux and tmuxinator I have come up with a customizable, reproducible way to spin up a development environment with a lot less effort. Over the years I have moved to doing almost all of my development in the terminal. My Tmuxline Config: # This tmux statusbar config was created by tmuxline.I spend a lot of time in the terminal. # set up aliases for temporarily maximizing panesīind Up new-window -d -n tmp \ swap-pane -s tmp.1 \ select-window -t tmpīind Down last-window \ swap-pane -s tmp.1 \ kill-window -t tmpīind P pipe-pane -o "cat >~/#W.log" \ display "Toggled logging to ~/#W.log" #bind C-v run "tmux set-buffer \"$(xclip -o -sel clipboard)\" tmux paste-buffer" #bind C-c run "tmux save-buffer - / xclip -i -sel clipboard" # xclip support (commented as this often doesn't make sense on remote servers) Setw -g window-status-current-attr bright Setw -g window-status-current-bg colour88 Set -g default-terminal "screen-256color" # disable mouse support (at least while we're learning) # vim / xmonad style bindings for window movement # vim / xmonad style bindings for pane movement # pass through a ctrl-a if you press it twice # start first window and pane at 1, not zeroīind r source-file ~/.nf \ display "Reloaded tmux config file." My Tmux config: # unbind some default keybindings I have disabled the "Treat Ambiguous characters as double width", but that doesn't fix it. When Splitting panes, borders looks bad both horizontally and vertically (the borders only go half-way and are dashes). I am currently using iTerm2, AMIX Vim, and Tmuxline (which includes vim airline).
