Skip to content

Instantly share code, notes, and snippets.

@AlexZeitler
Last active March 20, 2021 12:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AlexZeitler/75f1570d671077bd99a14a98cab4bc17 to your computer and use it in GitHub Desktop.
Save AlexZeitler/75f1570d671077bd99a14a98cab4bc17 to your computer and use it in GitHub Desktop.
tmux / tmuxinator named panes sample
# enable named panes
set -g pane-border-format "#{pane_index} #{pane_title}"
set -g pane-border-status bottom
name: my stack
root: ../
# Runs before everything. Use it to start daemons etc.
on_project_start:
- echo starting stack...
# Runs in each window and pane before window/pane specific commands. Useful for setting up interpreter versions.
# pre_window: rbenv shell 2.0.0-p247
# Pass command line options to tmux. Useful for specifying a different tmux.conf.
# tmux_options: -f ~/.tmux.mac.conf
# Specifies (by name or index) which window will be selected on project startup. If not set, the first window is used.
# startup_window: input
pre_window:
windows:
- workspace:
layout: even-vertical
panes:
- health:
- printf '\033]2;%s\033\\' 'healthcheck'
- work:
- printf '\033]2;%s\033\\' 'workspace'
- idp:
layout: even-vertical
panes:
- keycloack:
- printf '\033]2;%s\033\\' 'keycloak'
- api:
layout: even-vertical
panes:
- database:
- printf '\033]2;%s\033\\' 'api-database'
- server:
- printf '\033]2;%s\033\\' 'api'
- workspace:
- printf '\033]2;%s\033\\' 'api-workspace'
- ui:
layout: even-vertical
panes:
- vite:
- printf '\033]2;%s\033\\' 'vite-build'
- workspace:
- printf '\033]2;%s\033\\' 'ui-workspace'

Requirements

tmux version 2.3 is the minimal requirement

tmux setup

Make sure to source the .tmux.conf with tmux

tmux source-file /path/to/.tmux.conf

closing all windows / panes

tmux kill-session
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment