From owner-freebsd-questions@freebsd.org Fri Oct 16 20:20:13 2020 Return-Path: Delivered-To: freebsd-questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id D85D143ED7C for ; Fri, 16 Oct 2020 20:20:13 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from mailman.nyi.freebsd.org (unknown [127.0.1.3]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCcvx4dkQz4751 for ; Fri, 16 Oct 2020 20:20:13 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: by mailman.nyi.freebsd.org (Postfix) id 7D87D43E6FE; Fri, 16 Oct 2020 20:20:13 +0000 (UTC) Delivered-To: questions@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7D4B243EBBA for ; Fri, 16 Oct 2020 20:20:13 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from be-well.ilk.org (be-well.ilk.org [23.30.133.173]) by mx1.freebsd.org (Postfix) with ESMTP id 4CCcvw6dwjz47B0 for ; Fri, 16 Oct 2020 20:20:12 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from lowell-desk.be-well.ilk.org (router.lan [172.30.250.2]) by be-well.ilk.org (Postfix) with ESMTP id 486F133C0C; Fri, 16 Oct 2020 16:20:07 -0400 (EDT) Received: by lowell-desk.be-well.ilk.org (Postfix, from userid 1147) id 5223816323B5; Fri, 16 Oct 2020 16:20:06 -0400 (EDT) From: Lowell Gilbert To: Robert Huff Cc: questions@freebsd.org Subject: Re: sh scripting question References: <20201016113408.16d58d68@archlinux> <24457.35680.223661.203846@jerusalem.litteratus.org> Reply-To: questions@freebsd.org Date: Fri, 16 Oct 2020 16:20:05 -0400 In-Reply-To: <24457.35680.223661.203846@jerusalem.litteratus.org> (Robert Huff's message of "Fri, 16 Oct 2020 08:00:32 -0400") Message-ID: <444kmtudmy.fsf@be-well.ilk.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain X-Rspamd-Queue-Id: 4CCcvw6dwjz47B0 X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd-questions-local@be-well.ilk.org has no SPF policy when checking 23.30.133.173) smtp.mailfrom=freebsd-questions-local@be-well.ilk.org X-Spamd-Result: default: False [0.07 / 15.00]; HAS_REPLYTO(0.00)[questions@freebsd.org]; ARC_NA(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_HAM_MEDIUM(-0.19)[-0.187]; NEURAL_HAM_LONG(-0.91)[-0.909]; MIME_GOOD(-0.10)[text/plain]; REPLYTO_DOM_NEQ_FROM_DOM(0.00)[]; DMARC_NA(0.00)[ilk.org]; AUTH_NA(1.00)[]; NEURAL_SPAM_SHORT(0.17)[0.170]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; R_SPF_NA(0.00)[no SPF record]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:7922, ipnet:23.30.0.0/15, country:US]; RCVD_COUNT_TWO(0.00)[2]; MAILMAN_DEST(0.00)[questions] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Oct 2020 20:20:13 -0000 Robert Huff writes: > OP here. > The filenames at hand were generated by "find" and - on casual > inspection - have no oddities other than the embedded spaces. Since find is in use, I think the canonical solution is to use "find -print0"..."xargs -0" But it's not always convenient to use that mechanism, so there are other methods that have been used quite a few times, depending on the tools the user is comfortable with. In my case, it might involve an inline sed invocation to add the quoting for the spaces. Be well.