acme: set $samfile (same as $%) during execution

R=rsc
CC=plan9port.codebot
http://codereview.appspot.com/6854092
This commit is contained in:
Marius Eriksen 2012-11-25 22:56:08 -05:00 committed by Russ Cox
parent e19fde3584
commit 2589c5c6ee
2 changed files with 3 additions and 0 deletions

View file

@ -527,6 +527,8 @@ producing output in a window labeled
.BR /home/rob/sam/+Errors .
The environment of such commands contains the variable
.B $%
and
.B $samfile
with value set to the filename of the window in which the command is run,
and
.B $winid

View file

@ -1421,6 +1421,7 @@ runproc(void *argvp)
if(filename){
putenv("%", filename);
putenv("samfile", filename);
free(filename);
}
c->md = fsysmount(rdir, ndir, incl, nincl);