From nobody Mon Mar 21 20:58:45 2022 X-Original-To: freebsd-questions@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 9AB2D1A1B9AA for ; Mon, 21 Mar 2022 20:58:48 +0000 (UTC) (envelope-from johnl@iecc.com) Received: from gal.iecc.com (gal.iecc.com [IPv6:2001:470:1f07:1126:0:43:6f73:7461]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "gal.iecc.com", Issuer "Let's Encrypt Authority X3" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4KMn5z6LRdz4pWD for ; Mon, 21 Mar 2022 20:58:47 +0000 (UTC) (envelope-from johnl@iecc.com) Received: (qmail 24078 invoked from network); 21 Mar 2022 20:58:47 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=iecc.com; h=date:message-id:from:to:cc:subject:in-reply-to:references:mime-version:content-type; s=5e0c.6238e707.k2203; bh=H5Xlg/45NdZh1CZ4a+/1FcpW4BgBkkogmdQi1+SAtP8=; b=ho4in6v9w9u0h5ZN7L6GhgVZnHwNqsxixEX4x8vWiPmUY82DjnovIulAYNBrelPQQVsJTTkzn6LO979do6nLffN8aEt76mbQcruoR2QKr8AlQ9HYPTQdlZEMkOgFNTBbN0FL4IzgLDgpeK75bLKTyVS+eLtaEl9pdDyzAR2YUsH8QK/m270xB3oznGtjG1AMgUAEMlJCOwJBkVjfkURQwqZuqQgf994Ij5r9Adj/e+2vMiiAWi1Gg/FKvYTOnHwBRqCstFs/+LGok7PLg57Q9YNZtlovVvdLLKfXk+/D98ZYJu8Xz7eOm/737H3p77LS5VAg65QzdloY0dJMimeKeA== Received: from ary.qy ([IPv6:2001:470:1f07:1126::78:696d:6170]) by imap.iecc.com ([IPv6:2001:470:1f07:1126::78:696d:6170]) with ESMTPS (TLS1.2 ECDHE-RSA AES-256-GCM AEAD) via TCP6; 21 Mar 2022 20:58:47 -0000 Received: by ary.qy (Postfix, from userid 501) id 39D773985189; Mon, 21 Mar 2022 16:58:45 -0400 (EDT) Received: from localhost (localhost [127.0.0.1]) by ary.qy (Postfix) with ESMTP id C2252398516B; Mon, 21 Mar 2022 16:58:45 -0400 (EDT) Date: 21 Mar 2022 16:58:45 -0400 Message-ID: From: "John R. Levine" To: "Ernie Luzar" Cc: freebsd-questions@freebsd.org X-X-Sender: johnl@ary.qy Subject: Re: Replacement for unzip of .7z compressed files. In-Reply-To: <6238E3DA.4090306@gmail.com> References: <20220321201919.925363984C21@ary.qy> <6238E3DA.4090306@gmail.com> List-Id: User questions List-Archive: https://lists.freebsd.org/archives/freebsd-questions List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-questions@freebsd.org X-BeenThere: freebsd-questions@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed X-Rspamd-Queue-Id: 4KMn5z6LRdz4pWD X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; dkim=none ("invalid DKIM record") header.d=iecc.com header.s=5e0c.6238e707.k2203 header.b=ho4in6v9; dmarc=pass (policy=none) header.from=iecc.com; spf=pass (mx1.freebsd.org: domain of johnl@iecc.com designates 2001:470:1f07:1126:0:43:6f73:7461 as permitted sender) smtp.mailfrom=johnl@iecc.com X-Spamd-Result: default: False [-4.20 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2001:470:1f07:1126::/64:c]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[text/plain]; NEURAL_HAM_SHORT(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_MED(-0.40)[2001:470:1f07:1126:0:43:6f73:7461:from,2001:470:1f07:1126:0:78:696d:6170:received]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(-0.50)[iecc.com,none]; DKIM_TRACE(0.00)[iecc.com:~]; R_DKIM_PERMFAIL(0.00)[iecc.com:s=5e0c.6238e707.k2203]; MLMMJ_DEST(0.00)[freebsd-questions]; FREEMAIL_TO(0.00)[gmail.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[]; ASN(0.00)[asn:6939, ipnet:2001:470::/32, country:US]; MID_RHS_MATCH_FROM(0.00)[] X-ThisMailContainsUnwantedMimeParts: N > Problem is how do I get the extracted file into a different directory? > I have a directory named DL with 5 different named .7z files and want to have > the unzipped version go to another directory named UZ with the 5 .7z files > having the same file names minus the .7z extension. for f in DL/*.7z do tar -x -C UZ -f $f done or maybe for f in DL/*.7z do tar -x -f $f -O > UZ/$(basename $f .7z) done If you want to rename the extracted file ths -s flag might do the trick. Regards, John Levine, johnl@taugh.com, Primary Perpetrator of "The Internet for Dummies", Please consider the environment before reading this e-mail. https://jl.ly