Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp4418606imm; Fri, 18 May 2018 04:56:57 -0700 (PDT) X-Google-Smtp-Source: AB8JxZq0BacpHmMybs4jFA/P5hicxoWK4kT3NH05Tc27LTSl9fEbNWTKuAORV92uz0wPP96r+KHI X-Received: by 2002:a17:902:8a81:: with SMTP id p1-v6mr9442710plo.33.1526644617789; Fri, 18 May 2018 04:56:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526644617; cv=none; d=google.com; s=arc-20160816; b=e8K1sbfe43gT+OzGFeXqLvlCzFnewAvjx7doL6xDK64de4o71R/RDacpcxNC9sbR8L nIIlfdxE8HFN2IyPXt/CHYrdLRijNoDKk3sCOnaHrlWPdvpOEQ1lQp81otgKb7IaxE8H RUjx+TC5fRFW/KhRCIj0G2AyU5TWcy5Rx0UmpO2Cq26Yj51EAMAVKpL7wgmuv7rKWtSX AovTSynlGME3Hj+5p+h4xj/Usoa6Vot+Po51o4M0+ZCV99lJwagbJoQHJtyPTUS8NZAS vN4cmJdPMWOiKiH3qEKB/AmlQ5dRh0oSEI6g+m8qOE4Mg+UV6kQ3l4GQ5Gg1jtdUGOHL dLrQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:content-disposition :mime-version:message-id:subject:cc:to:from:date:dkim-signature :arc-authentication-results; bh=jHREgnckeZVRvMwBZJuZWoSQh50DN0DeNZOE/AQv+9A=; b=WInbr9MC/WWkSzo6lzeDLtqYa9bumvzurLDZibxC14fCeWv3N4q6JhhQRbrA4MGLun yJfE6Waa609y5dFvNqp4EWwEl7MeQFPenqpO+dxIj+BrlIXSW+0IqDo0/XX2sJJJOU7N WyMknlZnUHNHqdlKBwFypO3TvsaeqoRW1CaQHDAVZ7odkJ2k34C0DRlh55EjCQZ426Gh EmrX6w4bSQTpk6+A7jZOMtVmDpjaDMDmze5KhUlmGtaMsANGRdxCbREm2UJbX4CX8Yvn 0NxjGc2Mk0tKuiSDBuT0KUMNlrg1mvcXqCChwepPklEc7LLJi8awaIO44OgWeP8fO4hS gIMg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=jhcfsK7i; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h64-v6si5927759pge.206.2018.05.18.04.56.43; Fri, 18 May 2018 04:56:57 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=jhcfsK7i; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751664AbeERL42 (ORCPT + 99 others); Fri, 18 May 2018 07:56:28 -0400 Received: from mail-pl0-f65.google.com ([209.85.160.65]:45561 "EHLO mail-pl0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751531AbeERL4W (ORCPT ); Fri, 18 May 2018 07:56:22 -0400 Received: by mail-pl0-f65.google.com with SMTP id bi12-v6so4452887plb.12 for ; Fri, 18 May 2018 04:56:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:mime-version:content-disposition :user-agent; bh=jHREgnckeZVRvMwBZJuZWoSQh50DN0DeNZOE/AQv+9A=; b=jhcfsK7iH4kKffYAkMWe3GkH5cQKhOywdDj2XVLuD6U07nba1TyHkK57yu7qoftiXt VU5gwGxuTA3IjkzNsUStBboHVcSWnieSG1sfnvsaVXmQSAfk08eBasYxvQmShREFiufk u/yhb4INcgpXri7bnG/NC1bxVEReSEMkfMca7Fh+Oz/ppZq36pHUSfJN2Q4damqI8HZj IngmOG9QLhbYV9JJUCD1Lvfs5NK2VHA+TNZmS+abNr6+WXriBxRv1S8PHiq1HAOXTEMz 816bzzt4/jZhCwcJR0bFzmpsaluUJ/oupionlhGoTLiYxvhbfxiRL0urv2gVRki7n7zy 4kbg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:mime-version :content-disposition:user-agent; bh=jHREgnckeZVRvMwBZJuZWoSQh50DN0DeNZOE/AQv+9A=; b=Pnr6WqopVI7Z29X3d9mU0pNoqbzSkrQOwyGr7m1XzJm5sIHFqUV/9IpdluWcn7IqUr 6ZqQYvmCnhLbb5+Y31kwhNfwMimE/WS2OonsOPlCaW3V+6PrfwgZMhVTTf3IaQUrROBB x+LX6HsE+QrpwIrptGjIi1s1sE11ksAJmzl9i08ccjjhyIX3Kj6lR4wIs23tJezzpaah 7hXPEaYJ4U3QV+YKqukT/gXpPNVvagTpLvxIxKnNuYg53NIEKP44QhGka8t+k4SY/xx5 0ca+4qWMcRhWRDsYaWoJs4DG8p4L6hN5e9ZFkJ0i0kAmrKYVfcDdFSmds3dqJFEn9Z7+ CQDQ== X-Gm-Message-State: ALKqPwdUfMQauJe5e/BYPMbVd51Ki3L0IwzaQoUJfVJvKzjVuMvcBwT0 K+5TunuWVmdF+aj9tWTKjhk= X-Received: by 2002:a17:902:7149:: with SMTP id u9-v6mr9178066plm.356.1526644581767; Fri, 18 May 2018 04:56:21 -0700 (PDT) Received: from gmail.com ([2605:e000:1117:c0e3:2e0:1bff:fe70:ea]) by smtp.gmail.com with ESMTPSA id a5-v6sm17475020pff.8.2018.05.18.04.56.20 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 18 May 2018 04:56:21 -0700 (PDT) Date: Fri, 18 May 2018 01:56:19 -1000 From: Joey Pabalinas To: Masahiro Yamada Cc: Andrew Morton , Linux Kernel Mailing List , Arend van Spriel , Robert Jarzmik , Joey Pabalinas Subject: [PATCH v4] scripts/tags.sh: use `find` for $ALLSOURCE_ARCHS generation Message-ID: <20180518115619.jqb4hqdym7fmrs2p@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="wytobq62ncva55nz" Content-Disposition: inline User-Agent: NeoMutt/20180323-62-378db9 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --wytobq62ncva55nz Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Parsing `ls` is fragile at best and _will_ fail when $tree contains spaces. Replace this with a find-generated string and directly assign it to $ALLSOURCE_ARCHS; a subshell is implied by $(), so `cd` doesn't affect the current working directory. Signed-off-by: Joey Pabalinas 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/scripts/tags.sh b/scripts/tags.sh index 78e546ff689c2d5f40..c08347fdeef12a7621 100755 --- a/scripts/tags.sh +++ b/scripts/tags.sh @@ -26,24 +26,15 @@ else fi =20 # ignore userspace tools ignore=3D"$ignore ( -path ${tree}tools ) -prune -o" =20 -# Find all available archs -find_all_archs() -{ - ALLSOURCE_ARCHS=3D"" - for arch in `ls ${tree}arch`; do - ALLSOURCE_ARCHS=3D"${ALLSOURCE_ARCHS} "${arch##\/} - done -} - # Detect if ALLSOURCE_ARCHS is set. If not, we assume SRCARCH if [ "${ALLSOURCE_ARCHS}" =3D "" ]; then ALLSOURCE_ARCHS=3D${SRCARCH} elif [ "${ALLSOURCE_ARCHS}" =3D "all" ]; then - find_all_archs + ALLSOURCE_ARCHS=3D"$(find "${tree}arch/" -mindepth 1 -maxdepth 1 -type d = -printf ' %f')" fi =20 # find sources in arch/$ARCH find_arch_sources() { --=20 2.17.0.rc1.35.g90bbd502d54fe92035.dirty --wytobq62ncva55nz Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEKlZXrihdNOcUPZTNruvLfWhyVBkFAlr+v2MACgkQruvLfWhy VBlPww/9H8KmT79aFo3HmikjUqjuI+Gv3Pbg5sXzACkVgO5RZEUCrWrNhZIU1r3V 9teWU8/ngA3Q/Ek5GohAnJ75DZ1jLFR0F71hd7Udrp+jIdavnenSYby9tkdRkrXs Z5AbS1JkMocxa2yhsyX82TSLPiSOGRV6BDdGZkEG8ppvJVlcXhbjwWInG2ULDaE9 AmiwEz8McqlCGBUek1ZwnCh9o1HpLSCZuGfGpiuWGy4QCUb/GZXqyjvatigMwSae pLgntnZKuayLx+d+qV3RblyZow9xu0fKGaYZjR8X4i+bD6oMSuPX75Ln6AzCkbJk oqd1ZMcgcef0tT53H6K8iIhdevV19aszQ9UR7iq3WxK0cqIYGU41orwhJwrAX+eg FCo99RkODWtj1HE18jf4dNyTypU8aX9cpIvEwTgFI5c3OZ/cODGVzz7EB6mIEkNZ B+Pb+EUtCWEI1WFHGcoXcOWLaiQt1JI96Zwp6NpVAFC3AOpBoegimW3Vjd/GpPg5 SBlJeADhSUM2IQLwyQaCB/E15B1FsBVCWwx/0bU4nXjnjp279PSbbRTe91sHAQEn ixlOWzTnZGAv1EePuD50nz5G9SBYy3WCxTPApaYajlHEuQqbM9W+lWXI3zZALrQX yyEhZFpDyTBj+hDzUnUao96auG4GsKhqMYae8w+FlEjjKzbc6E8= =2a/n -----END PGP SIGNATURE----- --wytobq62ncva55nz--