#!/bin/sh # Installing packages (doing the real dist-upgrade) # gettext domain TEXTDOMAIN="lliurex-up" export TEXTDOMAIN COMMON_LIBRARY="/usr/share/lliurex-up/common-upgrade-vars.sh" if [ -r $COMMON_LIBRARY ] ; then . $COMMON_LIBRARY fi # Configuration file for GRUB TIME_GRUB_CFG_FILE="/etc/grub.d/00_header" #gettext messages INFO_MESSAGE="$(gettext "Fix video mode on grub")" # Methods _fix_video_mode() { echo "Fixing video mode on grub configuration" # Test if file exists if [ -f ${TIME_GRUB_CFG_FILE} ]; then echo " * [LliureX Up] Changed file: ${TIME_GRUB_CFG_FILE}" sed -e "s%gfxterm\=1%gfxterm\=0%g" -i "${TIME_GRUB_CFG_FILE}" fi } _info() { echo "$INFO_MESSAGE" } _migrate() { _fix_video_mode } _usage() { echo "# Unknown argument" } _die() { echo "Error: $1" exit 1 } ACTION="$1" case "$ACTION" in migrate) _migrate ;; info) _info ;; *) _usage ;; esac