37
loading...
This website collects cookies to deliver better user experience
tmux-start.sh
file & make it executable:$ touch tmux-start.sh
$ chmod +x tmux-start.sh
#!/bin/bash
session="webpack-ts"
tmux new-session -d -s $session
window=0
tmux rename-window -t $session:$window 'git'
tmux send-keys -t $session:$window 'git fetch --prune --all' C-m
C-m
after the command.git
, because I like having all the preview git commands on the screen when I run a new one.window=1
tmux new-window -t $session:$window -n 'vim'
tmux send-keys -t $session:$window 'vim package.json'
vim
, and type the command to start the editor. I don't call it automatically - after getting to the window, I'll have to press enter myself.window=2
tmux new-window -t $session:$window -n 'run'
window=3
tmux new-window -t $session:$window -n 'serve'
tmux send-keys -t $session:$window 'npm run serve'
tmux attach-session -t $session
./tmux-start.sh
:#!/bin/bash
session="webpack-ts"
tmux new-session -d -s $session
window=0
tmux rename-window -t $session:$window 'git'
tmux send-keys -t $session:$window 'git fetch --prune --all' C-m
window=1
tmux new-window -t $session:$window -n 'vim'
tmux send-keys -t $session:$window 'vim package.json'
window=2
tmux new-window -t $session:$window -n 'run'
window=3
tmux new-window -t $session:$window -n 'serve'
tmux send-keys -t $session:$window 'npm run serve'
tmux attach-session -t $session