automate/tmux-patterns.txt

68 lines
1.5 KiB
Plaintext

Python virtualenvs
what i do is that i edit the activate script and add
tmux set-environment VIRTUAL_ENV $VIRTUAL_ENV
after that, inside activate script there is deactivate function, i edit that function and add
tmux set-environment -r VIRTUAL_ENV
this way after i start venv all windows and panes will open with venv inside that session. If i deactivate new windows will open normal.
----
tmuxp.yaml in the root of the project.
session_name: tmuxp
start_directory: ./ # load session relative to config location (project root).
before_script: ./.tmuxp-before-script.sh
shell_command_before:
- '[ -f .venv/bin/activate ] && source .venv/bin/activate && reset'
windows:
- window_name: tmuxp
focus: True
layout: main-horizontal
options:
main-pane-height: 35
panes:
- focus: true
- pane
- make watch_test
- window_name: docs
layout: main-horizontal
options:
main-pane-height: 35
start_directory: docs/
panes:
- focus: true
- pane
- make serve
- make SPHINXBUILD='poetry run sphinx-build' watch
----------------
session_name: live-sdk
start_directory: ../live-sdk
before_script:./install.sh
windows:
- window_name: live-sdk
focus: True
layout: main-horizontal
options:
main-pain-height: 35
panes:
- focus: true
- pane
- source sdk
- load devuan devuan-desktop-metal chimaera
- window_name: live-metal
layout: main-horizontal
options:
main-pane-height: 35
start_directory: ./
panes:
- focus: true
- pane
- ls .