X-Git-Url: https://iankelling.org/git/?a=blobdiff_plain;f=install-chboot;h=041302df3904e109b8b669dfb113551904eb1fda;hb=HEAD;hp=69f46dfb99848bbbdd6641a98ae15108d0df165a;hpb=875cea0c266c7802b336f5a8b61b63e109e670fb;p=automated-distro-installer diff --git a/install-chboot b/install-chboot index 69f46df..041302d 100755 --- a/install-chboot +++ b/install-chboot @@ -15,24 +15,20 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -[[ $EUID == 0 ]] || exec sudo -E "$BASH_SOURCE" "$@" +[[ $EUID == 0 ]] || exec sudo -E "${BASH_SOURCE[0]}" "$@" -set -eE -o pipefail -trap 'echo "$0:$LINENO:error: \"$BASH_COMMAND\" returned $?" >&2' ERR - - -x=$(readlink -f "$BASH_SOURCE"); cd ${x%/*} +set -e; . /usr/local/lib/bash-bear; set +e usage() { - cat </dev/null || continue if [[ -e $dir/boot ]]; then dir=$dir/boot