Skip to content
Snippets Groups Projects
Commit 48138975 authored by Rashed Abdel-Tawab's avatar Rashed Abdel-Tawab Committed by qjohn
Browse files

mido: Update to show usage for new extract_files features

* Allows extracting only a specific section from proprietary-files.txt
* Defaults to not cleaning vendor folder before extraction
* Adds script options rather than depending on apredefined order

Change-Id: I74cd3bf4a1f652232c97c78d6164f0730599c1a7
parent 34d367d4
No related branches found
No related tags found
No related merge requests found
......@@ -34,25 +34,31 @@ if [ ! -f "$HELPER" ]; then
fi
. "$HELPER"
if [ $# -eq 0 ]; then
SRC=adb
else
if [ $# -eq 1 ]; then
SRC=$1
else
echo "$0: bad number of arguments"
echo ""
echo "usage: $0 [PATH_TO_EXPANDED_ROM]"
echo ""
echo "If PATH_TO_EXPANDED_ROM is not specified, blobs will be extracted from"
echo "the device using adb pull."
exit 1
fi
# default to not sanitizing the vendor folder before extraction
clean_vendor=false
while [ "$1" != "" ]; do
case $1 in
-p | --path ) shift
SRC=$1
;;
-s | --section ) shift
SECTION=$1
clean_vendor=false
;;
-c | --clean-vendor ) clean_vendor=true
;;
esac
shift
done
if [ -z "$SRC" ]; then
SRC=adb
fi
# Initialize the helper
setup_vendor "$DEVICE" "$VENDOR" "$CM_ROOT"
setup_vendor "$DEVICE" "$VENDOR" "$CM_ROOT" false $clean_vendor
extract "$MY_DIR"/proprietary-files.txt "$SRC"
extract "$MY_DIR"/proprietary-files.txt "$SRC" "$SECTION"
"$MY_DIR"/setup-makefiles.sh
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment