code: 9ferno

ref: e81c54ba2ecc673a4d5f8aed0e9b52841fe07b0d
dir: /lib/sh/profile/

View raw version
# sh initialisation here
load std

user = `{cat /dev/user}
home = /usr/^$user
pubgridreg = tcp!registry.9p.zone!registry
cd $home

# build the user's namespace in $home/
and {ftest -e namespace}	{nsbuild}

if{~ $#emuhost 0 && ~ $#emuwdir 0}{
	# running native

	# load a heap based filesystem on /tmp
	memfs
}{
	# running hosted

	# dis/init has set this up already for native booting
	mount {mntgen} /n
}

# Run the user's profile
and {ftest -e lib/profile}	{run ./lib/profile}