version 1.75, 2015/05/03 00:27:01 |
version 1.78, 2015/10/12 00:35:14 |
|
|
#!/bin/sh |
#!/bin/sh |
# $AFresh1: update_openbsd,v 1.74 2015/03/21 22:50:18 andrew Exp $ |
# $AFresh1: update_openbsd,v 1.77 2015/05/03 00:11:52 andrew Exp $ |
# |
# |
# Copyright (c) 2012 Andrew Fresh <andrew@afresh1.com> |
# Copyright (c) 2012 Andrew Fresh <andrew@afresh1.com> |
# |
# |
|
|
local _file=$1 |
local _file=$1 |
# This could go circular, but I dunno how to fix that. |
# This could go circular, but I dunno how to fix that. |
if [ -h $_file ]; then |
if [ -h $_file ]; then |
follow_symlink $( file $_file | |
follow_symlink $( readlink -f $_file ) |
grep 'symbolic link' | |
|
sed -e s/^.*\\\`// -e s/\\\'\$// ) |
|
else |
else |
echo $_file |
echo $_file |
fi |
fi |
|
|
echo "!!! at the end of the proces but it is safer to !!!" >&2 |
echo "!!! at the end of the proces but it is safer to !!!" >&2 |
echo "!!! have a separate root shell open. !!!" >&2 |
echo "!!! have a separate root shell open. !!!" >&2 |
echo "!!! It is needed in order to run /sbin/oreboot. !!!" >&2 |
echo "!!! It is needed in order to run /sbin/oreboot. !!!" >&2 |
echo "!!! sudo MAY NOT WORK after sets are extracted. !!!" >&2 |
echo "!!! doas MAY NOT WORK after sets are extracted. !!!" >&2 |
echo >&2 |
echo >&2 |
echo "enter to continue, ctrl+C to cancel" >&2 |
echo "enter to continue, ctrl+C to cancel" >&2 |
local _temp |
local _temp |
|
|
fi |
fi |
update_etc |
update_etc |
|
|
echo '==> UPDATING PACKAGES' |
OPENUP=$( which openup ) |
pkg_add -ui -F update -F updatedepends |
if [ -n "$OPENUP" ]; then |
|
echo "==> UPDATING WITH $OPENUP" |
|
$OPENUP |
|
else |
|
echo '==> UPDATING PACKAGES' |
|
pkg_add -ui -F update -F updatedepends |
|
fi |
|
|
echo '==> UPDATING FIRMWARE' |
echo '==> UPDATING FIRMWARE' |
fw_update |
fw_update |