From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: John Darrington Newsgroups: gmane.lisp.guile.user Subject: Re: How to pass something on to xargs rm? Date: Tue, 27 Dec 2016 13:07:50 +0100 Message-ID: <20161227120750.GA16030@jocasta.intra> References: <87d1gd7gji.fsf@wasp.i-did-not-set--mail-host-address--so-tickle-me> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="huq684BweRXVnRxX" X-Trace: blaine.gmane.org 1482840517 20811 195.159.176.226 (27 Dec 2016 12:08:37 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 27 Dec 2016 12:08:37 +0000 (UTC) User-Agent: Mutt/1.5.23 (2014-03-12) Cc: guile-user@gnu.org To: ng0 Original-X-From: guile-user-bounces+guile-user=m.gmane.org@gnu.org Tue Dec 27 13:08:32 2016 Return-path: Envelope-to: guile-user@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cLqYP-0004WP-8U for guile-user@m.gmane.org; Tue, 27 Dec 2016 13:08:29 +0100 Original-Received: from localhost ([::1]:53762 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cLqYU-0008Kw-0D for guile-user@m.gmane.org; Tue, 27 Dec 2016 07:08:34 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:32989) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cLqY2-0008Kr-0A for guile-user@gnu.org; Tue, 27 Dec 2016 07:08:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cLqXy-0007hU-Pi for guile-user@gnu.org; Tue, 27 Dec 2016 07:08:05 -0500 Original-Received: from de.cellform.com ([88.217.224.109]:51990 helo=jocasta.intra) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cLqXy-0007f6-HM for guile-user@gnu.org; Tue, 27 Dec 2016 07:08:02 -0500 Original-Received: from jocasta.intra (localhost [127.0.0.1]) by jocasta.intra (8.14.4/8.14.4/Debian-8+deb8u1) with ESMTP id uBRC7pX9016090 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 27 Dec 2016 13:07:51 +0100 Original-Received: (from john@localhost) by jocasta.intra (8.14.4/8.14.4/Submit) id uBRC7onQ016089; Tue, 27 Dec 2016 13:07:50 +0100 Content-Disposition: inline In-Reply-To: <87d1gd7gji.fsf@wasp.i-did-not-set--mail-host-address--so-tickle-me> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 88.217.224.109 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane.org@gnu.org Original-Sender: "guile-user" Xref: news.gmane.org gmane.lisp.guile.user:13063 Archived-At: --huq684BweRXVnRxX Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Dec 27, 2016 at 11:33:21AM +0000, ng0 wrote: Hi, =20 I have some scripts and small applications I'm slowly moving over to guile. One of them features this[0] line at the end which passes results on to xargs rm. I picked a start with just (system*) everything I had before to learn about the behavior and outcome, and improve from this point. I know that "|" will not work, so what else could possibly work (for starters, in the long run I'll generalize and extend what I currently have) to execute this command which deletes every file listed in the previous search? =20 [0]: notmuch search --output=3Dfiles tag:deleted | xargs -L 1 rm =20 I think you want something like: .... | xargs -I {} rm {} J' --=20 Avoid eavesdropping. Send strong encrypted email. PGP Public key ID: 1024D/2DE827B3=20 fingerprint =3D 8797 A26D 0854 2EAB 0285 A290 8A67 719C 2DE8 27B3 See http://sks-keyservers.net or any PGP keyserver for public key. --huq684BweRXVnRxX Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAlhiWZYACgkQimdxnC3oJ7MDHgCeM5Ee8x7IUyKFv96l8K8P4PpX wnEAnigE9RGpyURj9awuJ5hnedlGQxBO =WVVv -----END PGP SIGNATURE----- --huq684BweRXVnRxX--