From 4a73c45eb625c4f020304d638e0b949b37c9e27e Mon Sep 17 00:00:00 2001 From: Dom Cobley Date: Mon, 24 Jul 2023 16:25:15 +0100 Subject: [PATCH] rpi-update: Warn against unsupported command line parameters There seem to be users who think passing '-y' or '-v' will do something useful. Explicitly warn against this. --- rpi-update | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/rpi-update b/rpi-update index 20dd2c4..880942b 100755 --- a/rpi-update +++ b/rpi-update @@ -3,6 +3,14 @@ set -o nounset set -o errexit +for i in $*; do + if [[ $i == -* ]]; then + echo "rpi-update does not accept command line dash parameters." + echo "See: https://github.com/raspberrypi/rpi-update/blob/master/README.md" + exit 1 + fi +done + REPO_URI=${REPO_URI:-"https://github.com/raspberrypi/rpi-firmware"} REPO_API_URI=${REPO_URI/github.com/api.github.com\/repos} REPO_CONTENT_URI=${REPO_URI/github.com/raw.githubusercontent.com}