From 9067b6e7302dafe5459c93532a9199d43eb7780f Mon Sep 17 00:00:00 2001 From: Miquel Sabaté Solà Date: Sat, 24 Aug 2024 22:36:20 +0200 Subject: kbuild: add a -h/--help command MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Miquel Sabaté Solà --- bin/kbuild | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/bin/kbuild b/bin/kbuild index f90f93d..3272403 100755 --- a/bin/kbuild +++ b/bin/kbuild @@ -23,11 +23,12 @@ # 4. Copy into a tarball the resulting image, modules, dtbs, and headers. An # install.sh script is also bundled in. # -# You can also pass two options: +# You can also pass some options: # 1. `-s/--skip-build`: tell to skip the call to `defconfig` and/or # `menuconfig`. This is useful if you are just developing over the same # `.config` file again and again. # 2. `-n/--no-install`: do not prepare the install/uninstall bundle. +# 3. `-h/--help`: show the help message. # # After that just send the resulting tarball to the machine where you want to # install this kernel. In there you just need to untar the given bundle and then @@ -58,6 +59,10 @@ while [[ $# -gt 0 ]]; do NO_INSTALL="t" shift ;; + -h | --help) + SHOW_HELP=1 + shift + ;; -*) echo "kbuild (error): unknown option '$1'." exit 1 @@ -69,6 +74,21 @@ while [[ $# -gt 0 ]]; do esac done +# Print the show message if needed. +if [ -n "$SHOW_HELP" ]; then + cat <>/boot/extlinux/extlinux.conf + ### ### NOTE: generated by kbuild. ### -- cgit v1.2.3