-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsession.sh
More file actions
29 lines (21 loc) · 869 Bytes
/
Copy pathsession.sh
File metadata and controls
29 lines (21 loc) · 869 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#!/bin/bash
SESSION="dotFiles"
TARGET_DIR=.
tmux kill-session -t "$SESSION" 2>/dev/null
# editor window
tmux new-session -d -s "$SESSION" -n "editor" -c "$TARGET_DIR"
tmux send-keys -t "$SESSION:editor" "nvim" C-m
# shell window
tmux new-window -t "$SESSION" -n "shell" -c "$TARGET_DIR"
# lazygit window
tmux new-window -t "$SESSION" -n "lazygit" -c "$TARGET_DIR"
tmux send-keys -t "$SESSION:lazygit" "lazygit" C-m
# superfile window
tmux new-window -t "$SESSION" -n "superfile" -c "$TARGET_DIR"
tmux send-keys -t "$SESSION:superfile" "spf" C-m
# opencode window (shell left 31%, opencode right 69%)
tmux new-window -t "$SESSION" -n "opencode" -c "$TARGET_DIR"
tmux split-window -h -t "$SESSION:opencode" -p 69 -c "$TARGET_DIR"
tmux send-keys -t "$SESSION:opencode.right" "opencode" C-m
tmux select-window -t "$SESSION:editor"
tmux attach-session -t "$SESSION"