CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In
sagemathinc

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place. Commercial Alternative to JupyterHub.

GitHub Repository: sagemathinc/cocalc
Path: blob/master/src/scripts/g-tmux.sh
Views: 926
1
#!/usr/bin/env bash
2
3
export PWD=`pwd`
4
tmux new-session -d -s mysession
5
tmux new-window -t mysession:1
6
tmux new-window -t mysession:2
7
sleep 2
8
tmux send-keys -t mysession:1 '$PWD/scripts/g.sh' C-m
9
sleep 2
10
tmux send-keys -t mysession:0 'pnpm database' C-m
11
12
if [ -n "$NO_RSPACK_DEV_SERVER" ]; then
13
sleep 2
14
tmux send-keys -t mysession:2 'pnpm rspack' C-m
15
else
16
sleep 2
17
tmux send-keys -t mysession:2 '$PWD/scripts/memory_monitor.py' C-m
18
fi
19
20
tmux attach -t mysession:1
21
22