From owner-freebsd-questions@freebsd.org Fri Jun 21 03:54:42 2019 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 027FA15CF3F4 for ; Fri, 21 Jun 2019 03:54:42 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.17.10]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.kundenserver.de", Issuer "TeleSec ServerPass Class 2 CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 98D8D7440A for ; Fri, 21 Jun 2019 03:54:40 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de ([94.222.12.231]) by mrelayeu.kundenserver.de (mreue108 [212.227.15.183]) with ESMTPA (Nemesis) id 1M3DFj-1hb9kB0Z25-003a7l for ; Fri, 21 Jun 2019 05:49:10 +0200 Date: Fri, 21 Jun 2019 05:49:09 +0200 From: Polytropon To: FreeBSD Questions Subject: How to un-select files in shell wildcard patterns Message-Id: <20190621054909.c6ba47ab.freebsd@edvax.de> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K1:0t5z0zzkT6d3tjhuzkhzpXffCFrOj0HmhU5ppw7E41w9vU4BsDF kGnt0798dDdwWYPcsbpgiTw+0b8fDvqbGEreF5s3004jd47oAIsthzY0YJNkdkg45TZtt57 Y4o6tW5ii14fBkfZ41PPuedm8h/FcPrgKzt5TBaEYs5zxGG8XP5QKVeppQPBeulKCHTQ42L 9ngY4ZjVeKxjmB6FHGpiA== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:nMreHB+elF8=:jC+n588ua3bb2dlmboQnZ4 l+kXDbUoCTwBou5m37cb2s8J8NOHKdD8Ba60vQ5uGMWOCZ+N0tMupIdWZ3daFEHGncRU/5oIH yf+cIssD0P8rA85FDou+68DZnc9arbQF6BhPOEuYUZSDoSvj3M8egne5Risdy+JXategfECEb RxeVjaO8XN0O5e5nvKw3tn2Y/nDiEM/qFwvl9DMsBShk8FVWjuuW49v8svQuIWi8LUe11DSMa Y4TARFOfUg2YXlJc8XuQ2gYk4pUDJjaZ5UB9Cfvp+6aHuUXpb0qeg2BgUsCiaLgvEJWc0uKgO VRjuEJG47+NlTr+pDAMl8Ujx7pV3Pu0eueeyT4ytGU8FQq7w/sH4lmiHIINzBvDsVJhdtGJuE ZLdS8Rme8880nRsJiJtFTQAkbSMSvRwBrYqizO0pCvcdOlDvEya5kvXMmP+yiRMg9bXSZCrV4 r3w00XjwaPq9ZaVgjGImj0a3+yaLTBfSCDLRIPqwMI4K8F1+ZepwZcRhoUZKVPDB5kpV/fDWS cI9CtruyV4mncrz2HG8FxnbIS/d+P0cneW6yWJfX8hdH60h4ILqCItxqYr2BHyoXLYmzfLrRQ KWGsGFieAsn1KFHu3TuF8s03i2ElADWv0SOz6VM27taCGWjnhr+LjJDqFUk18aM/MRUMcK+BK iE2Opb8kwFnmhLse1SDGjkHUdbfNbKFRc02VWXLLCP7q+ySZdfgo0/Uu6QLb757cJFQqVeJqw S0fLf1WnnbL3SUAV3A01HJutjcA4WQ5CeZyaJat8j+tb/5f+IWAz9vA9f+k= X-Rspamd-Queue-Id: 98D8D7440A X-Spamd-Bar: ++++ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [4.22 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; HAS_REPLYTO(0.00)[freebsd@edvax.de]; MV_CASE(0.50)[]; HAS_ORG_HEADER(0.00)[]; TO_DN_ALL(0.00)[]; MX_GOOD(-0.01)[mx01.schlund.de,mx00.schlund.de]; RECEIVED_SPAMHAUS_PBL(0.00)[231.12.222.94.zen.spamhaus.org : 127.0.0.11]; RCVD_TLS_LAST(0.00)[]; MIME_TRACE(0.00)[0:+]; FROM_EQ_ENVFROM(0.00)[]; ASN(0.00)[asn:8560, ipnet:212.227.0.0/16, country:DE]; ARC_NA(0.00)[]; REPLYTO_EQ_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(0.47)[0.474,0]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-questions@freebsd.org]; DMARC_NA(0.00)[edvax.de]; AUTH_NA(1.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_SPAM_MEDIUM(0.48)[0.484,0]; R_DKIM_NA(0.00)[]; NEURAL_SPAM_LONG(0.94)[0.941,0]; RCVD_IN_DNSWL_NONE(0.00)[10.17.227.212.list.dnswl.org : 127.0.5.0]; MID_CONTAINS_FROM(1.00)[]; R_SPF_NA(0.00)[]; RWL_MAILSPIKE_POSSIBLE(0.00)[10.17.227.212.rep.mailspike.net : 127.0.0.17]; RCVD_COUNT_TWO(0.00)[2]; IP_SCORE(-0.07)[ip: (-1.45), ipnet: 212.227.0.0/16(-1.42), asn: 8560(2.50), country: DE(-0.01)] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Jun 2019 03:54:42 -0000 I'm interested in a convenient method to "un-select" files when using regular (sh) shell wildcards. It's quite easy to describe things like *.tex to perform an operation on all LaTeX source files, or *a* on all files whose name contains (at least) one "a". Patterns that are based on the inclusion of certain attributes are not a problem to deal with using the builtin pattern matching of the shell. But what about the opposite? Let's say, perform an operation on all files _except_ the LaTeX source files, or all files whose name does _not_ contain an "a"? Is there a good method to do this, except creating a kind of "custom regex wrapper script" that does the selection part, for further use with `subshell` or | xargs? -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...