scripts/config: add -y|-n flags

Add alias -y ("yes") to --enable and -n ("no") to --disable a Kconfig
option for better scripting experience.

Signed-off-by: Denis Mukhin <dmukhin@ford.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
This commit is contained in:
Denis Mukhin authored and Stefano Stabellini committed 2026-02-04 15:42:23 -08:00
1 parent 0081a505b3
commit 74bcaa9283
1 file changed
+4 -4
+4 -4
View File
@@ -16,8 +16,8 @@ Manipulate options in a .config file from the command line.
Usage:
$myname options command ...
commands:
--enable|-e option Enable option
--disable|-d option Disable option
--enable|-e|-y|--yes option Enable option
--disable|-d|-n|--no option Disable option
--set-str option string
Set option to "string"
--set-val option value
@@ -166,11 +166,11 @@ while [ "$1" != "" ] ; do
;;
esac
case "$CMD" in
--enable|-e)
--enable|-e|-y|--yes)
set_var "${CONFIG_}$ARG" "${CONFIG_}$ARG=y"
;;
--disable|-d)
--disable|-d|-n|--no)
set_var "${CONFIG_}$ARG" "# ${CONFIG_}$ARG is not set"
;;
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.