From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HTML_MESSAGE,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 25696 invoked from network); 4 Feb 2023 03:31:10 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 4 Feb 2023 03:31:10 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1675481470; b=The3G7xwtW1zfDoZbsBOO4DX7llhciXbVLAnytBppG8W7n1in4FtZIdTMRXJKGFirgOjJibXoN A6mlhO/qvtpFdJixnJkkG4o3+DXo5fJvKU4g1N2U4gZ6zZOPW4bdhAbkL2k0StberWjAqLpKU1 tlh3h36QJJhGZFG8kBhPKb5q9C4l7KmmLXz772k7CbuV2pkNc3UrPatKEgSR4+XE11ZmNjH7G4 Pk1fokieg9B/YvKPgEykOuPINm8XCzJEbkjiHK+TSKAZSrtuGXXREDfkD75hS2aV46ziBBOXg7 xlIUjftd1f2NVs6tk0JV+k95y0Tf2OR5wIEBpA1WHek75Q==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (102c.relay.hey.com) smtp.remote-ip=204.62.115.201; dkim=pass header.d=hey.com header.s=heymail header.a=rsa-sha256; dmarc=pass header.from=hey.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1675481470; bh=naxlfir3ojCwkU1q/lYiOlnCD+IULDo3nGpraHn6BTo=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Transfer-Encoding:Content-Type:MIME-Version:Subject: In-Reply-To:Message-ID:To:From:Date:DKIM-Signature:DKIM-Signature; b=JQpIc4KIja4pBiXPUrVyGxr8WBurDlTAK/nY3VwXSLfsJgSe8/C2M/Jy14baO9u1SHIuA8rWzR UsqAV2cx+lNbpcyFqm3dsKb9lpCT/ZtdQ9y8ioNldTPcKb7u/gwSGol8cZir8XqPm/1qdNxQ6n 9tCUa40fTO3/iiaH/r8JdjnwurQd+/NsJl6L5FLJQ44itE1RNdwnFoujTL5Ia4mjwbpH/xaXDb ymOsppip9lhiK2uCkepL9tnmT7CGv8t30aax+H7JFmspcZr19xikT5fc/AVItxjWoRkdkUu9fW jzHyEoQUtHKNCW7nJBGJ7qlZ6X6AfuqmJKrW5K1d9fYyzA==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20210803; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Transfer-Encoding: Content-Type:Mime-Version:Subject:In-Reply-To:Message-ID:To:From:Date: Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:References; bh=hB41nlJLPfINn8SKy7ZfCPVYZ61fGUD3JCSye6a/m/M=; b=Am0v3I6GNuDUhFore+mphdFtQd KAVL2WOldevKtluYcRnxwbpMwPcKmH49QKnThxYTgTDuusobkvXXbYTKTtpkZ+A4IZMpP5c/XlVuy 9U91iIiOqLYZUyMyNxIYsqtssgn3PsctXTn6GBeLKv0r9szevo5ca0GNPzQDzFTS7VTS9C0N02xhR R+Ocm4nqtkNDLgbidV9KzSe3zzpdS5SDxUox3HZ4YPbxc9pAM3upsm/Li84mwySbH/eGAhKo2q/CY +43AabqHmprasG/dDv6dMstc4vnajcKmwKndwG8KUAXey54VVQN+swx1EezDkErQZBFQQ+6HQHbnC L0I2ZKbg==; Received: by zero.zsh.org with local id 1pO9Ge-000Hg1-6j; Sat, 04 Feb 2023 03:31:08 +0000 Authentication-Results: zsh.org; iprev=pass (102c.relay.hey.com) smtp.remote-ip=204.62.115.201; dkim=pass header.d=hey.com header.s=heymail header.a=rsa-sha256; dmarc=pass header.from=hey.com; arc=none Received: from 102c.relay.hey.com ([204.62.115.201]:40171) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_256_GCM_SHA384:256) id 1pO9Fo-000Gyj-2N; Sat, 04 Feb 2023 03:30:17 +0000 Received: from hey.com (bigip-vip.rw-ash-int.37signals.com [10.20.0.24]) by 102.relay.hey.com (Postfix) with ESMTPS id BCD2921535; Sat, 4 Feb 2023 03:30:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hey.com; s=heymail; t=1675481414; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to; bh=hB41nlJLPfINn8SKy7ZfCPVYZ61fGUD3JCSye6a/m/M=; b=Gp+n5r1hqTRlOfwRNpO283gQ00xYL+6l58DvkeiFblb1Ge2jlKeTUPttdnsH3sglWaGghx QzkSyNI8Mta66HYitKSR4WxCKMw7wNo7560dUV7SRtjebyiZwHOPPzYZrV5w09QhDOzcg4 5+1+KTQlXpWARwZrmtwqVp7O7Qd6MYdrs4zHI8XaSiRwD/JsFyxKTWeaACc7lJXkKAgsb8 XFPf0Pymkxz1APw8V4tN3SY1+A7H5rQYYl0Eq7VzA9NyrAJ45orr5D/Yg748xsJfY3aE9B edxt/8OlQoOpdDDSEEHFnuxKgFqzerhEYM6Dq+MbKq8389MBZpmzIc+2tDxyfg== Date: Fri, 03 Feb 2023 22:30:14 -0500 From: Eric Nielsen To: "zsh-users@zsh.org" , sergio Message-ID: In-Reply-To: Subject: Re: join a string with a parameter value if it's not empy Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="--==_mimepart_63ddd146517ff_27ef1d9c286aa"; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Seq: 28899 Archived-At: X-Loop: zsh-users@zsh.org Errors-To: zsh-users-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-users-request@zsh.org X-no-archive: yes List-Id: List-Help: , List-Subscribe: , List-Unsubscribe: , List-Post: List-Owner: List-Archive: ----==_mimepart_63ddd146517ff_27ef1d9c286aa Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit > Is it possible to construct an array without a tmp parameter? I can think of: ${(j:_:)${=:-$p string whatever else}} -- Sent with HEY ----==_mimepart_63ddd146517ff_27ef1d9c286aa Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
> Is it possible to construct an array without a tmp parameter?=

I can think of:

${(j:_:)${=3D:-$p string whatever else}}


--
Sent with HEY
----==_mimepart_63ddd146517ff_27ef1d9c286aa--