-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvoyage.update
executable file
·40 lines (35 loc) · 936 Bytes
/
voyage.update
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#!/bin/bash
#
# This is the entry-level script for Voyage configuration.
# It prompts the user to determine whether this is a new
# installation, or an update to an existing system.
#
# by default export all variables
set -a
# remember the current dir for future use and get the path to
# the directory where this script is located
RUNDIR=$PWD
cd `dirname $0`
EXECDIR=$PWD
cd $RUNDIR
# load the script containing our utility routines
source $EXECDIR/script-utils.sh
# select-profile is a separate script but usually needed
source $EXECDIR/select-profile.sh
case "$1" in
-i) v=1
shift
;;
-u) v=2
shift
;;
*) # now ask what the user wants to do
OPTIONS="1:Create new Voyage Linux disk:%2:Update existing Voyage configuration:%3:Exit:"
ask_setting "What would you like to do?" "$OPTIONS" 1
;;
esac
case $v in
1) $EXECDIR/voyage-install.sh "$@";;
2) $EXECDIR/voyage-update.sh;;
*) err_quit "No action taken";;
esac