summaryrefslogtreecommitdiff
path: root/package/base-files
diff options
context:
space:
mode:
Diffstat (limited to 'package/base-files')
-rw-r--r--package/base-files/extra/etc/profile6
-rwxr-xr-xpackage/base-files/extra/init3
-rwxr-xr-xpackage/base-files/extra/sbin/update14
3 files changed, 10 insertions, 13 deletions
diff --git a/package/base-files/extra/etc/profile b/package/base-files/extra/etc/profile
index 798548a46..1b8f4a6a6 100644
--- a/package/base-files/extra/etc/profile
+++ b/package/base-files/extra/etc/profile
@@ -1,12 +1,12 @@
export PATH=/bin:/sbin:/usr/bin:/usr/sbin
+export TERM=vt220
if [[ $(id -u) = 0 ]]; then
export PS1='# '
else
export PS1='$ '
+ export HOME=/tmp
fi
-export HOME=/tmp
cat /etc/banner 2>&-
-[ -x /usr/bin/less ] || alias less=more
-[ -x /usr/bin/vim ] || alias vim=vi
+[ -x /usr/bin/vim ] && alias vi=vim || alias vim=vi
[ -x /usr/bin/arp ] || arp() { cat /proc/net/arp; }
[ -x /usr/bin/ldd ] || ldd() { LD_TRACE_LOADED_OBJECTS=1 "$@"; }
diff --git a/package/base-files/extra/init b/package/base-files/extra/init
index 9013065d0..db8c3a676 100755
--- a/package/base-files/extra/init
+++ b/package/base-files/extra/init
@@ -1,5 +1,5 @@
#!/bin/sh
-echo "Pre-boot initializing"
+echo "Starting system ..."
export PATH=/bin:/sbin:/usr/bin:/usr/sbin
mount -nt proc proc /proc
mount -o nosuid,nodev,noexec -t sysfs sysfs /sys
@@ -19,5 +19,4 @@ mount -o remount,rw /
cat /etc/.rnd >/dev/urandom 2>&1
[ -f /etc/fstab ] && mount -a
[ -x /sbin/cfgfs ] && { cfgfs setup; mount -o remount,ro /;}
-echo "Starting system"
exec /sbin/init
diff --git a/package/base-files/extra/sbin/update b/package/base-files/extra/sbin/update
index a812bb23d..10d6e58c2 100755
--- a/package/base-files/extra/sbin/update
+++ b/package/base-files/extra/sbin/update
@@ -7,9 +7,8 @@ if [ $who -ne 0 ]; then
fi
cd /
-
+umount -f /etc
mount -o remount,rw /
-umount /etc
check_exit() {
if [ $? -ne 0 ];then
@@ -19,17 +18,17 @@ check_exit() {
}
extract_from_file() {
- tar -xzvf $1
+ cat $1 | gunzip -c | tar -xf -
check_exit
}
extract_from_ssh() {
- ssh $1 "cat $2" | tar -xzvf -
+ ssh $1 "cat $2" | gunzip -c | tar -xf -
check_exit
}
extract_from_http() {
- wget -O - $1 | tar -xzvf -
+ wget -O - $1 | gunzip -c | tar -xf -
check_exit
}
@@ -60,7 +59,6 @@ case $1 in
esac
sync
-mount --bind /etc /tmp/.cfgfs/root
+mount -o bind /etc /tmp/.cfgfs/root
-echo "Check with cfgfs status if you need to merge and save any changes in /etc."
-echo "You should reboot now."
+echo "Update sucessful. You should reboot now."