Created
September 25, 2025 14:14
-
-
Save jreypo/b53f5e335ea24cc31fd0d2dc68573d8a to your computer and use it in GitHub Desktop.
tmux startup script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| SESSION=dev | |
| # If session already exists, just attach | |
| if tmux has-session -t $SESSION 2>/dev/null; then | |
| tmux attach -t $SESSION | |
| exit 0 | |
| fi | |
| # Otherwise create new one | |
| tmux new-session -d -s $SESSION -n main | |
| tmux new-window -t $SESSION:1 -n devlab | |
| tmux new-window -t $SESSION:2 -n blog | |
| tmux attach -t $SESSION:0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment