Begin moving arg parsing to install.sh

I chose to make the arg parsing in install.sh a function because it
simplifies handling positional arguments in the interim without messing
with arrays.  Just serves to get our foot in the door for arg processing
for now.
This commit is contained in:
T. Joseph Carter 2018-05-10 08:35:50 -07:00
parent 3e961cd4b5
commit 331f4be653

View File

@ -10,6 +10,8 @@
a2cloudVersion="2.9.0" # Leave this quoted!
noPicoPkg=
# Find the path of our source directory
a2cSource="$( dirname "${BASH_SOURCE[0]}" )"
pushd $a2cSource >/dev/null
@ -20,6 +22,20 @@ if [[ ! -f "$a2cSource/.a2cloud_source" ]]; then
exit 1
fi
process_args() {
while [[ $1 ]]; do
if [[ $1 == "-c" ]]; then
shift
noPicoPkg=1
else
shift
fi
done
}
process_args "$@"
# FIXME: Show version, changes, config, allow reconfig, etc…
"$a2cSource/scripts/show_changes"
# Run the legacy setup script for anything not yet ported