From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20241 invoked by alias); 25 Jan 2011 19:43:42 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 15732 Received: (qmail 25918 invoked from network); 25 Jan 2011 19:43:39 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received-SPF: pass (ns1.primenet.com.au: SPF record at ntlworld.com designates 81.103.221.47 as permitted sender) Date: Tue, 25 Jan 2011 19:43:27 +0000 From: Peter Stephenson To: zsh-users@zsh.org Subject: Re: Adding file name completions Message-ID: <20110125194327.6034db79@pws-pc.ntlworld.com> In-Reply-To: References: X-Mailer: Claws Mail 3.7.8 (GTK+ 2.22.0; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Cloudmark-Analysis: v=1.1 cv=R50lirqlHffDPPkwUlkuVa99MrvKdVWo//yz83qex8g= c=1 sm=0 a=kj9zAlcOel0A:10 a=pGLkceISAAAA:8 a=NLZqzBF-AAAA:8 a=AdenT1BqsDi7lIRpZD0A:9 a=Ew1NzEk6S7d9aT2QJmxybN3za-QA:4 a=CjuIK1q_8ugA:10 a=MSl-tDqOz04A:10 a=_dQi-Dcv4p4A:10 a=HpAAvcLHHh0Zw7uRqdWCyQ==:117 On Tue, 25 Jan 2011 00:50:08 -0500 Jean-Rene David wrote: > If I type a command name followed by and I find the completer for > that command doesn't complete filenames, is there a way to tell zsh to > add filename completion? Your simplest bet is to have a separate function to complete files, else you would need to modify the completion function directly. The following binds this to C-x f. zle -C complete-file complete-word _generic zstyle ':completion:user-expand:*' completer _user_expand zstyle ':completion:complete-file:*' completer _path_files bindkey '^xf' complete-file -- Peter Stephenson Web page now at http://homepage.ntlworld.com/p.w.stephenson/