My favorites | Sign in
Project Home Downloads Wiki Issues Source
Repository:
Checkout   Browse   Changes   Clones  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#!/dis/sh.dis
# emu sh initialisation here
load std

user="{cat /dev/user}
home=/usr/^$"user
mount -ac {mntgen} /n
ftrans=()

if {~ $emuhost MacOSX Linux}{
trfs '#U*' /n/local >[2] /dev/null
ftrans = $frans '#U*' /n/local
ghome=/n/local/^`{echo 'echo $HOME' | os sh}
}{~ $emuhost Nt}{
for i in C D { # add more drive letters to suit
trfs '#U' ^ $i ^ ':/' /n/$i >[2] /dev/null
ftrans = $ftrans '#U' ^ $i ^ ':/' /n/$i
}
ghome=`{os cmd /c 'echo %APPDATA%' |
tr -d '
'| sed -n '
s/ /␣/g
s/\\/\//g
s/^([A-Z]):/\/n\/\1/p'}
}{ else
ghome=$home
}
lhome=$ghome^/acme-home
mount -a {mntgen} /usr

# setup for 1st time user
if {! ftest -d $lhome}{
cp -r /usr/inferno $lhome
bind -c /usr/inferno $home
mkdir -p $home/tmp
}

bind -c $lhome $home
bind -bc $home/tmp /tmp

cd $home
run $home/lib/profile

Change log

de19f3c165ae by Caerwyn Jones <caerwynj> on May 28, 2009   Diff
use latest sh.b from inferno-os
Go to: 
Project members, sign in to write a code review

Older revisions

58627b76057a by Caerwyn Jones <caerwynj> on May 20, 2009   Diff
update ftrans in profile. fix os -t
2663c6e48394 by saoret.one on Mar 15, 2008   Diff
lib/sh/profile cleanup
5bba72e6448b by caerwynj on Nov 10, 2007   Diff
fix to get APPDATA on Vista
All revisions of this file

File info

Size: 818 bytes, 42 lines
Powered by Google Project Hosting