diff options
| -rwxr-xr-x | builder/build-initramfs.sh | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/builder/build-initramfs.sh b/builder/build-initramfs.sh index 2bca9ca5..710676a5 100755 --- a/builder/build-initramfs.sh +++ b/builder/build-initramfs.sh @@ -1,8 +1,6 @@ #!/usr/bin/env bash # -*- coding: utf-8 -*- - # region header - # Copyright Torben Sickert (info["~at~"]torben.website) 29.10.2015 # Janosch Dobler (info["~at~"]jandob.com) 29.10.2015 @@ -59,11 +57,8 @@ exceptions.activate core.import logging core.import utils core.import change_root - # endregion - # region properties - dracut_resource_url='https://www.kernel.org/pub/linux/utils/boot/dracut/dracut-043.tar.gz' file_path='/boot/initramfs.img' dracut_parameter='--force --no-hostonly' @@ -97,13 +92,9 @@ declare -A optional_shared_library_pattern_dependencies=() declare -A core_package_dependencies=() declare -A optional_package_dependencies=( ['fuse glib-2.0 pixman-1']='support template systems in container (usually used by virtual runtime environments)') - # endregion - # region functions - ## region command line interface - print_usage_message() { # Prints a description about how to use this program. logging.cat << EOF @@ -253,11 +244,8 @@ parse_command_line() { fi return 0 } - ## endregion - ## region helper - dependency_check() { # Check for given dependencies with given dependency checker and log # corresponding messages. @@ -330,13 +318,9 @@ cleanup() { clean return $? } - ## endregion - # endregion - # region controller - result=0 if ! [ -f "/lib/modules/$(uname --kernel-release)/build/Makefile" ];then logging.critical 'Missing core dependency "linux-headers" to compile against given or current kernel.' @@ -364,9 +348,7 @@ dependency_check optional shared_library_pattern_dependencies \ dependency_check optional package_dependencies \ utils_dependency_check_pkgconfig package || result=$? [[ $result == 1 ]] && exit $result - ## region handle delegated operations to specified target - if [[ "$target" != '' ]]; then _target="$target" if [[ -f "$target" ]]; then @@ -423,11 +405,8 @@ if [[ "$target" != '' ]]; then fi exit 0 fi - ## endregion - ## region handle dependencies which can be resolved automatically - logging.info 'Checking dracut.' if [[ ! -f "$(dirname "${BASH_SOURCE[0]}")/dracut/dracut-install" ]]; then logging.info "Dracut isn't available yet loading it." @@ -450,11 +429,8 @@ then "$_dracut_modules_target" fi fi - ## endregion - ## region prepare and perform final dracut call - _loglevel='' if [ "$verbose" == 'yes' ]; then _loglevel='--verbose' @@ -500,14 +476,9 @@ else exceptions.activate fi exceptions.deactivate - ## endregion - # endregion - # region vim modline - # vim: set tabstop=4 shiftwidth=4 expandtab: # vim: foldmethod=marker foldmarker=region,endregion: - # endregion |
