From patchwork Wed Oct 28 00:42:04 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Olof Johansson X-Patchwork-Id: 7505841 Return-Path: X-Original-To: patchwork-linux-kbuild@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 8DAD79F36A for ; Wed, 28 Oct 2015 00:46:01 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id B328C2053E for ; Wed, 28 Oct 2015 00:46:00 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id C78A82053A for ; Wed, 28 Oct 2015 00:45:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754853AbbJ1Aml (ORCPT ); Tue, 27 Oct 2015 20:42:41 -0400 Received: from mail-pa0-f47.google.com ([209.85.220.47]:33150 "EHLO mail-pa0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752677AbbJ1Amj (ORCPT ); Tue, 27 Oct 2015 20:42:39 -0400 Received: by pabla5 with SMTP id la5so44894594pab.0 for ; Tue, 27 Oct 2015 17:42:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lixom_net.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=DgzP0ENoy0UpZ9nqzFZHtf0ZB6NHpBs/hSc+YoFtNk4=; b=pK0aSwjgFb/vPVd6r6ZCx0z5O7pv6EV1AOxvjCZ2c6V5JOQxW8qZVarLwZMrQGi31F 8FItt7axbstNxdmNtNEnUTfpnVxKlAfLMj+v0R9M6RK0LUE+juGPVPMICHn6F4nJNRas Q5pPbkDXhylAgozyTT1qAdx4CSl0nFhMf1wCAk/865NEKWsrNL3BRoN7FNVDAEJGGg3B SPDx3QYJtqq+1bVWXbjUvU6Ws7oqiNCdhTjQ7KKG62lHOsKEwng1HOBAi/vmbgGHPMam 69CE6tJeCDxvZUZ/IcetOu/5IrnWYntiuLg7bchVVnReDiRJtEShBxqvxQ2fzcb4NcrR xAyg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=DgzP0ENoy0UpZ9nqzFZHtf0ZB6NHpBs/hSc+YoFtNk4=; b=UIwcxqO3fwPauEu76r54A01B5qckZe9U0q1vTL+4wLGtiynJNBBBCxzv/6Px9E5NvA 8B864matWfG6TGIe8M+HixNyD0gNmTtPJwJ0AoKOmhvWD67PoZ+kMjfj+tj80OBLSqUP ANoi6zscdXcb8i9eyxKw4/nMzGja+IHteCmici2vybIp54FoHLC2/XE0NguDQPc0kfmu +H6mjLDX0oxn2YWo/EL8VVD8++9dTbpgjSsUR0ZsoDFaQIXZHPS9jafsV516Y+yjBBOJ h/pDUhV4plXLLIuW5xLCGi0EQ/uN2Urz7limIU4THlKN4fzG7yRzTjzos6jVCBmAbt0/ NRKQ== X-Gm-Message-State: ALoCoQmow0Y9fs9/AftIpE6/3pMBZJc9UKZHprbaSZxAJwyaVPMMQrlVmkcWjAlbPzSUAHq3uWCU X-Received: by 10.68.135.40 with SMTP id pp8mr30905972pbb.50.1445992959549; Tue, 27 Oct 2015 17:42:39 -0700 (PDT) Received: from localhost.localdomain ([58.123.138.250]) by smtp.gmail.com with ESMTPSA id t9sm41801385pbs.17.2015.10.27.17.42.36 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 27 Oct 2015 17:42:38 -0700 (PDT) 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-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Every case that continues iterating needs a shift, so move it to common location. Also, the continues are redundant. Signed-off-by: Olof Johansson Reviewed-by: Darren Hart --- 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