From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25423 invoked by alias); 3 Mar 2014 15:39:35 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 32458 Received: (qmail 2116 invoked from network); 3 Mar 2014 15:39:28 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.co.uk; s=s1024; t=1393860839; bh=g1tvPmOX3B88XcHn9O6pc/6SjzDFtzRc4cCt8yR9QIE=; h=X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:X-Rocket-Received:Received:In-reply-to:From:References:To:Subject:MIME-Version:Content-Type:Content-ID:Date:Message-ID; b=jGnEa2CgqyKVMPMbI+heFIUayYaVLX62tqyDFaj8yUFqvuqx33D7AGGyJVimBvnSs7xOFJAzZGmLsCfaezPNNlAVfAqMBU9sh8nItGzMwmpAD3cdsT6euKjNyg/y1Iwb6ZfoLK+yT1fmYa462pr6fzfTsXOab8AeXRdbscyXBK0= X-Yahoo-Newman-Id: 534942.18046.bm@smtp137.mail.ir2.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: bHdA2xAVM1kKKxMUFpStu7fOlWQAQ97cL8gkq8W9HuRafB7 dqJBg5OAzjvNeX6cLA80FWGbs0aLaEfI5QyLyTfChCfsGhhbOYsE79FfRwi_ 498kjg2HzygQaPFdZ.b9IJmC2GoH_mOEUrPKT5_HMU8pVvq6_GthT7cjolry QZRVqwUfLws4mO3emHd3Vvhyw461gIE43HixuwmGqJiVmGkOZ3ohRzNnDVVp 6_3TKNVE_4A0wjROfRrqP.4FLT1UNP35pHgICkmmw_mA0f9soCjzzLvoLgYN VPG5hE3lsxFki..GpgZ4yJsVOtA0TDBxZItVRry1.55N6Xt_PzT8gWpjXsmQ rGGrPKspBr3ZqMod0EDhRsa65YLTEHekZ9pcNFz.BhUDsU6n1IXd6pFvuBIo b.4xIosvB19gVFgQWQbgxirDgIhts8nVRlfL0S.zrQhjL6TE3uYR.1YXgpQq dZsmPb96FuXv7z6emcD0J3oC281YDCJishl3ZFa31cQwcXSywuqNH4YegEb_ m4w3lRPDhuXT.swBgXdcbbeEeZlxh X-Yahoo-SMTP: opAkk_CswBAce_kJ3nIPlH80cJI- X-Rocket-Received: from kiddle.eu (okiddle@95.222.208.151 with plain [188.125.69.59]) by smtp137.mail.ir2.yahoo.com with SMTP; 03 Mar 2014 15:33:59 +0000 UTC In-reply-to: From: Oliver Kiddle References: <29011.1393594448@thecus.kiddle.eu> <626.1393625311@thecus.kiddle.eu> To: Zsh workers Subject: Re: completer for file extensions MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <30072.1393860830.1@thecus.kiddle.eu> Date: Mon, 03 Mar 2014 16:33:58 +0100 Message-ID: <30074.1393860838@thecus.kiddle.eu> Mikael Magnusson wrote: > I have a number of screenshots with . in the name and it causes these > completions to be added; > .00.png .09.16.png .13580 .16.png .36.04.png .58.png > I guess you go for the first . to get stuff like .tar.gz? Tarballs It takes all of them, so for foo-1.0.tar.gz, it will add .gz .tar.gz and .0.tar.gz. Incidentally, that's what the {1.. brace expansion that was mistakenly {1- is for (along with the I flag). > often have . in the name for version numbers so I have the same issue > in that directory; Numbers alone are I think a rare choice for file extensions so I'll add in: files=( ${files:#.<->(.*|)} ) You might still find cases where dots are used but not meant as extensions: something like .rc2 or .5-dev-0 but you wouldn't want, e.g. .mp3 filtered. You can always use an ignored-patterns style. The change above is equivalent to doing: zstyle ':completion:*:extensions:*' ignored-patterns '.<->(.*|)' Oliver