Fri Dec 11, 2015 3:04 am
Fri Dec 11, 2015 3:19 am
Fri Dec 11, 2015 8:56 am
Fri Dec 11, 2015 11:19 am
# make some basic entries in /target/dev so the system can boot properly before udev starts
# rsync excluded /dev/*
mknod -m 622 /target/dev/console c 5 1
mknod -m 666 /target/dev/null c 1 3
mknod -m 666 /target/dev/zero c 1 5
mknod -m 666 /target/dev/ptmx c 5 2
mknod -m 666 /target/dev/tty c 5 0
mknod -m 444 /target/dev/random c 1 8
mknod -m 444 /target/dev/urandom c 1 9
chown -v root:tty /target/dev/{console,ptmx,tty}
ln -sv /proc/self/fd /target/dev/fd
ln -sv /proc/self/fd/0 /target/dev/stdin
ln -sv /proc/self/fd/1 /target/dev/stdout
ln -sv /proc/self/fd/2 /target/dev/stderr
ln -sv /proc/kcore /target/dev/core
ln -sv /run/shm /target/dev/shm
mkdir -v /target/dev/pts
Fri Dec 11, 2015 11:55 am
if [ -f /target/home/"$newusername"/.gconf/apps/gksu/%gconf.xml ]; then
sed -i '/sudo-mode/s/true/false/' /target/home/"$newusername"/.gconf/apps/gksu/%gconf.xml
fi
sed -i 's/SU_TO_ROOT_SU=sudo/SU_TO_ROOT_SU=su/' /target/home/$newusername/.su-to-rootrc
# detects .kde/ .kde4/ .trinity/ (kdesurc or tdesurc)
for file in /target/home/$newusername/.*/share/config/*desurc ; do
sed -i 's/super-user-command=sudo/super-user-command=su/' $file
done
Fri Dec 11, 2015 12:02 pm
Sat Dec 12, 2015 10:02 am