Last active
March 15, 2020 02:07
-
-
Save jackiect/1a18cad0929a2bec1b4eb13c2dc00323 to your computer and use it in GitHub Desktop.
Revisions
-
jackiect revised this gist
Mar 14, 2020 . 2 changed files with 16 additions and 16 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,20 +1,20 @@ #!/bin/sh # ensure tmux window and pane index begin at 1 w=1 tmux new-session -s 'tmux-container' -d 'sh command.sh "w='$w'&p=1" ; sh' tmux split-window -h 'sh command.sh "w='$w'&p=2" ; sh' tmux split-window -v 'sh command.sh "w='$w'&p=3" ; sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "w='$w'&p=4" ; sh' for i in {2..5} do tmux new-window -n w-$i -e 'W='$i -d 'sh command.sh "w='$i'&p=1" ; sh' tmux select-window -t $i tmux split-window -h 'sh command.sh "w='$i'&p=2" ; sh' tmux split-window -v 'sh command.sh "w='$i'&p=3" ; sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "w='$i'&p=4" ; sh' done tmux -2 attach-session -d 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 charactersOriginal file line number Diff line number Diff line change @@ -1,24 +1,24 @@ #!/bin/sh # ensure tmux window and pane index begin at 1 h=0 tmux new-session -s 'tmux-container' -d 'sh command.sh "-h'$h' -p0" ; sh' tmux split-window -h 'sh command.sh "-h'$h' -p1" ; sh' h=1 tmux split-window -v 'sh command.sh "-h'$h' -p0" ; sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "-h'$h' -p1" ; sh' for i in {2..11} do ha=$((i*2-2)) hb=$((ha+1)) w="$ha-$hb" tmux new-window -n w-$w -e 'W='$w -d 'sh command.sh "-h'$ha' -p0" ; sh' tmux select-window -t $i tmux split-window -h 'sh command.sh "-h'$ha' -p1" ; sh' tmux split-window -v 'sh command.sh "-h'$hb' -p0" ; sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "-h'$hb' -p1" ; sh' done tmux -2 attach-session -d -
jackiect revised this gist
Mar 14, 2020 . 2 changed files with 16 additions and 16 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,20 +1,20 @@ #!/bin/sh # ensure tmux window and pane index begin at 1 w=1 tmux new-session -s 'tmux-container' -d 'sh command.sh "w='$w'&p=1" & sh' tmux split-window -h 'sh command.sh "w='$w'&p=2" & sh' tmux split-window -v 'sh command.sh "w='$w'&p=3" & sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "w='$w'&p=4" & sh' for i in {2..5} do tmux new-window -n w-$i -e 'W='$i -d 'sh command.sh "w='$i'&p=1" & sh' tmux select-window -t $i tmux split-window -h 'sh command.sh "w='$i'&p=2" & sh' tmux split-window -v 'sh command.sh "w='$i'&p=3" & sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "w='$i'&p=4" & sh' done tmux -2 attach-session -d 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 charactersOriginal file line number Diff line number Diff line change @@ -1,24 +1,24 @@ #!/bin/sh # ensure tmux window and pane index begin at 1 h=0 tmux new-session -s 'tmux-container' -d 'sh command.sh "-h'$h' -p0" & sh' tmux split-window -h 'sh command.sh "-h'$h' -p1" & sh' h=1 tmux split-window -v 'sh command.sh "-h'$h' -p0" & sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "-h'$h' -p1" & sh' for i in {2..11} do ha=$((i*2-2)) hb=$((ha+1)) w="$ha-$hb" tmux new-window -n w-$w -e 'W='$w -d 'sh command.sh "-h'$ha' -p0" & sh' tmux select-window -t $i tmux split-window -h 'sh command.sh "-h'$ha' -p1" & sh' tmux split-window -v 'sh command.sh "-h'$hb' -p0" & sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "-h'$hb' -p1" & sh' done tmux -2 attach-session -d -
jackiect revised this gist
Mar 14, 2020 . 2 changed files with 2 additions and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,4 +1,5 @@ #!/bin/sh # ensure tmux window and pane index begin at 1 w=1 tmux new-session -s 'tmux-container' -d 'sh command.sh "w='$w'&p=1" && sh' tmux split-window -h 'sh command.sh "w='$w'&p=2" && sh' 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 charactersOriginal file line number Diff line number Diff line change @@ -1,5 +1,5 @@ #!/bin/sh # ensure tmux window and pane index begin at 1 h=0 tmux new-session -s 'tmux-container' -d 'sh command.sh "-h'$h' -p0" && sh' tmux split-window -h 'sh command.sh "-h'$h' -p1" && sh' -
jackiect revised this gist
Mar 14, 2020 . 2 changed files with 2 additions and 2 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -5,4 +5,4 @@ url="http://httpbin.org/get?p=$p" curl -i $url cmd="cd ~/tmp/tmp && pwd && echo $p && curl -sL '$url'" ssh chen@localhost "$cmd" 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 charactersOriginal file line number Diff line number Diff line change @@ -5,4 +5,4 @@ url="http://httpbin.org/get?$q" curl $url cmd="cd /tmp && ls && echo $p && curl -sL '$url'" ssh chen@localhost "$cmd" -
jackiect revised this gist
Mar 14, 2020 . 1 changed file with 24 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,24 @@ #!/bin/sh # ensure tmux window index begin at 1 h=0 tmux new-session -s 'tmux-container' -d 'sh command.sh "-h'$h' -p0" && sh' tmux split-window -h 'sh command.sh "-h'$h' -p1" && sh' h=1 tmux split-window -v 'sh command.sh "-h'$h' -p0" && sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "-h'$h' -p1" && sh' for i in {2..11} do ha=$((i*2-2)) hb=$((ha+1)) w="$ha-$hb" tmux new-window -n w-$w -e 'W='$w -d 'sh command.sh "-h'$ha' -p0" && sh' tmux select-window -t $i tmux split-window -h 'sh command.sh "-h'$ha' -p1" && sh' tmux split-window -v 'sh command.sh "-h'$hb' -p0" && sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "-h'$hb' -p1" && sh' done tmux -2 attach-session -d -
jackiect revised this gist
Mar 14, 2020 . 1 changed file with 6 additions and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,3 +1,8 @@ #!/bin/sh set -x q=$@ url="http://httpbin.org/get?$q" curl $url cmd="cd /tmp && ls && echo $p && curl -sL '$url'" ssh tanchen01@localhost "$cmd" -
jackiect revised this gist
Mar 14, 2020 . 1 changed file with 8 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,8 @@ #!/bin/sh set -x p=$@ url="http://httpbin.org/get?p=$p" curl -i $url cmd="cd ~/tmp/tmp && pwd && echo $p && curl -sL '$url'" ssh tanchen01@localhost "$cmd" -
jackiect revised this gist
Mar 14, 2020 . 1 changed file with 6 additions and 4 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,8 +1,10 @@ #!/bin/sh w=1 tmux new-session -s 'tmux-container' -d 'sh command.sh "w='$w'&p=1" && sh' tmux split-window -h 'sh command.sh "w='$w'&p=2" && sh' tmux split-window -v 'sh command.sh "w='$w'&p=3" && sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "w='$w'&p=4" && sh' for i in {2..5} do -
jackiect revised this gist
Mar 14, 2020 . 1 changed file with 14 additions and 7 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,10 +1,17 @@ tmux new-session -s 'tmux-container' -d 'sh command.sh "w=1&p=1" && sh' tmux split-window -h 'sh command.sh "w=1&p=2" && sh' tmux split-window -v 'sh command.sh "w=1&p=3" && sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "w=1&p=4" && sh' for i in {2..5} do tmux new-window -n w-$i -e 'W='$i -d 'sh command.sh "w='$i'&p=1" && sh' tmux select-window -t $i tmux split-window -h 'sh command.sh "w='$i'&p=2" && sh' tmux split-window -v 'sh command.sh "w='$i'&p=3" && sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh "w='$i'&p=4" && sh' done tmux -2 attach-session -d -
jackiect revised this gist
Mar 14, 2020 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -5,6 +5,6 @@ tmux split-window -v 'sh command.sh q=3 && sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh q=4 && sh' for i in {2..5}; do tmux new-window -n w-$i -d; done tmux -2 attach-session -d -
jackiect revised this gist
Mar 14, 2020 . 2 changed files with 2 additions and 5 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -5,6 +5,6 @@ tmux split-window -v 'sh command.sh q=3 && sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh q=4 && sh' for i in {1..5}; do tmux new-window -d; done tmux -2 attach-session -d 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 charactersOriginal file line number Diff line number Diff line change @@ -1,6 +1,3 @@ #!/bin/sh set -x curl -i http://httpbin.org/get?$@ -
jackiect revised this gist
Mar 14, 2020 . 1 changed file with 7 additions and 10 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,13 +1,10 @@ #!/bin/sh tmux new-session -s 'tmux-container' -d 'sh command.sh q=1 && sh' tmux split-window -h 'sh command.sh q=2 && sh' tmux split-window -v 'sh command.sh q=3 && sh' tmux select-pane -t 1 tmux split-window -v 'sh command.sh q=4 && sh' tmux new-window -d tmux -2 attach-session -d -
jackiect revised this gist
Mar 14, 2020 . 2 changed files with 12 additions and 2 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -3,4 +3,11 @@ tmux new-session -d 'vim && sh' tmux split-window -v 'ipython && sh' tmux split-window -h 'sh command.sh && sh' tmux new-window 'mutt' tmux -2 attach-session -d #tmux new-session -d 'sh command.sh q=1 && sh' #tmux split-window -v 'sh command.sh q=2 && sh' #tmux split-window -h 'sh command.sh q=3 && sh' #tmux new-window 'mutt' #tmux -2 attach-session -d 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 charactersOriginal file line number Diff line number Diff line change @@ -1,3 +1,6 @@ #!/bin/sh set -x curl -i http://httpbin.org/get?q=3 #set -x #curl -i http://httpbin.org/get?$@ -
jackiect created this gist
Mar 14, 2020 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1 @@ https://stackoverflow.com/questions/5609192/answer/5752901 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,6 @@ #!/bin/sh tmux new-session -d 'vim && sh' tmux split-window -v 'ipython && sh' tmux split-window -h 'sh command.sh && sh' tmux new-window 'mutt' tmux -2 attach-session -d 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,3 @@ #!/bin/sh set -x curl -i http://httpbin.org/get?q=3