mirror of
https://github.com/9fans/plan9port.git
synced 2025-01-12 11:10:07 +00:00
wintext: use rc not bash
This commit is contained in:
parent
0a7fe60681
commit
0bd1478342
1 changed files with 9 additions and 14 deletions
23
bin/wintext
23
bin/wintext
|
@ -1,22 +1,17 @@
|
||||||
#!/bin/bash
|
#!/usr/local/plan9/bin/rc
|
||||||
|
|
||||||
case "$winid" in
|
if(~ $winid [0-9]*) {
|
||||||
[0-9]*)
|
|
||||||
9p read acme/$winid/body
|
9p read acme/$winid/body
|
||||||
exit 0
|
exit 0
|
||||||
esac
|
}
|
||||||
|
if(~ $text9term 'unix!'*) {
|
||||||
case "$text9term" in
|
dial -e $text9term < /dev/null
|
||||||
unix!*)
|
|
||||||
dial -e $text9term </dev/null
|
|
||||||
exit 0
|
exit 0
|
||||||
esac
|
}
|
||||||
|
if(~ $TMUX ?*) {
|
||||||
case "$TMUX" in
|
|
||||||
?*)
|
|
||||||
tmux capture-pane -p
|
tmux capture-pane -p
|
||||||
exit 0
|
exit 0
|
||||||
esac
|
}
|
||||||
|
|
||||||
echo 'no running window found' 2>&1
|
echo 'no running window found' >[2=1]
|
||||||
exit 1
|
exit 1
|
||||||
|
|
Loading…
Reference in a new issue