From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754897AbbJ1Amm (ORCPT ); Tue, 27 Oct 2015 20:42:42 -0400 Received: from mail-pa0-f43.google.com ([209.85.220.43]:35073 "EHLO mail-pa0-f43.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754839AbbJ1Amk (ORCPT ); Tue, 27 Oct 2015 20:42:40 -0400 From: Olof Johansson To: Michal Marek Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, dvhart@linux.intel.com, Olof Johansson Subject: [PATCH 03/10] merge_config.sh: minor argument parsing refactoring Date: Wed, 28 Oct 2015 09:42:04 +0900 Message-Id: <1445992931-28107-4-git-send-email-olof@lixom.net> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1445992931-28107-1-git-send-email-olof@lixom.net> References: <1445992931-28107-1-git-send-email-olof@lixom.net> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Every case that continues iterating needs a shift, so move it to common location. Also, the continues are redundant. Signed-off-by: Olof Johansson --- scripts/kconfig/merge_config.sh | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/scripts/kconfig/merge_config.sh b/scripts/kconfig/merge_config.sh index 0e98619..fd0d537 100755 --- a/scripts/kconfig/merge_config.sh +++ b/scripts/kconfig/merge_config.sh @@ -48,13 +48,9 @@ while true; do case $1 in "-n") ALLTARGET=allnoconfig - shift - continue ;; "-m") RUNMAKE=false - shift - continue ;; "-h") usage @@ -62,8 +58,6 @@ while true; do ;; "-r") WARNREDUN=true - shift - continue ;; "-O") if [ -d $2 ];then @@ -72,13 +66,14 @@ while true; do echo "output directory $2 does not exist" 1>&2 exit 1 fi - shift 2 - continue + shift ;; *) break ;; esac + + shift done if [ "$#" -lt 1 ] ; then -- 2.1.4