setup-ivi-sh-functions: introduce a newline variable
[platform/adaptation/setup-scripts.git] / setup-gummiboot-conf
index dbd4dfc..b344029 100755 (executable)
@@ -8,9 +8,11 @@ PROG="setup-gummiboot-conf"
 VER="1.0"
 
 srcdir="$(readlink -ev -- ${0%/*})"
-PATH="/usr/share/setup-ivi:$srcdir:$PATH"
-
-. setup-ivi-sh-functions
+if [ -f "$srcdir/setup-ivi-sh-functions" ]; then
+       . "$srcdir/setup-ivi-sh-functions"
+else
+       .  /usr/share/setup-ivi/setup-ivi-sh-functions
+fi
 
 # This is a small trick which I use to make sure my scripts are portable -
 # check if 'dash' is present, and if yes - use it.
@@ -51,6 +53,7 @@ create_default_conf_file()
 
        mkdir -p $verbose "$conf_dir" >&2
        cat > "$conf_file" <<-EOF
+       # Generated by $PROG
        timeout 0
        default $1
        EOF
@@ -182,6 +185,7 @@ add_subcommand()
        # Create the new entry
        mkdir -p $verbose "$entries_dir" >&2
        cat > "$entry_path" <<-EOF
+       # Generated by $PROG
        title $title
        version $kernel_version
        efi /$kernel