rcmain: use new $termprog variable
R=rsc
CC=plan9port.codebot
https://codereview.appspot.com/12505045
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index c49c9cd..b62df5c 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -44,6 +44,7 @@
Russ Cox <rsc@swtch.com>
Sean McKean <smckean83@gmail.com>
Shenghou Ma <minux.ma@gmail.com>
+Steve McCoy <mccoyst@gmail.com>
Ties Bos <gitbisector@gmail.com>
Tim Newsham <tim.newsham@gmail.com>
Tony Lainson <t.lainson@gmail.com>
diff --git a/rcmain b/rcmain
index 448de02..461cb3e 100644
--- a/rcmain
+++ b/rcmain
@@ -23,7 +23,7 @@
exit $status
}
if(flag i){
- if(~ $TERM 9term){
+ if(~ $termprog 9term || ~ $termprog win){
fn cd {
# builtin cd $1 && flag i && awd
# is not sufficient when running in a subshell