shithub: purgatorio

ref: a411870ee4640241e3c494367d922847da84f972
dir: purgatorio/appl/lib/workdir.b

View raw version
implement Workdir;

include "sys.m";

include "workdir.m";

init(): string
{
	sys := load Sys Sys->PATH;
	fd := sys->open(".", Sys->OREAD);
	if(fd == nil)
		return nil;
	return sys->fd2path(fd);
}