From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19964 invoked by alias); 30 Jul 2013 23:19:49 -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: 17899 Received: (qmail 6732 invoked from network); 30 Jul 2013 23:19:33 -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.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW, T_TO_NO_BRKTS_FREEMAIL autolearn=ham version=3.3.2 Received-SPF: pass (ns1.primenet.com.au: SPF record at _netblocks.google.com designates 209.85.214.43 as permitted sender) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to:content-type; bh=TbTH5Rmb36MVlKIPzPJot+hwdJnt64OzctUSFsRQv3Q=; b=elaGjmtBO11Z+Nd6FYgFIFAsPO9DmSPtuzkoP1tDe/s4YrAzqx8Opw5HFbqPES7nYN AMsoLYz6FgJ7weDc1ZKGUwu2JgiuSiBQXOC1Qf3kn9Nv/G21g/6BfnxWKbb7jzFqL6P8 N1GZLzbnZgbEesQpYyvJ2oYm51xtbQFH+rv0Kb+V6h7nTcDekiLwLYRrKrC4y17K/kvS onztPPEi6hkbBTjGe6c9km9aLFTNr8qbRdZ9gfpNxlYy8r/GIJ/Nsmhs4t3OPO6ETo78 gO3oc+URbj3lbBokWuSnMoLYBJOpvTP/bMFqwHI4gbOBg7c/mnKUBgjCs+WDojtSPUNC yoGQ== X-Received: by 10.204.163.142 with SMTP id a14mr9499631bky.59.1375226365110; Tue, 30 Jul 2013 16:19:25 -0700 (PDT) MIME-Version: 1.0 From: Felipe Sateler Date: Tue, 30 Jul 2013 19:18:45 -0400 Message-ID: Subject: Loading completion function from custom fpath To: zsh-users@zsh.org Content-Type: text/plain; charset=UTF-8 Hi all, I'm having some issues with zsh that I hoped you could give some help. I'm trying to add custom completion functions (I'm trying to create a new one). However, as I do not want to use root, I want the new completion functions to live within my $HOME. Google tells me that all that I needed to do is create a directory, add it to fpath in my zshrc, and be done with it. However, this doesn't work. My zshrc says: ===== fpath=('~/.zsh/functions' $fpath) zstyle :compinstall filename '/home/felipe/.zshrc' autoload -Uz compinit compinit ===== I have deposited a completion for the gbp command in ~/.zsh/functions/_gbp, yet the completion system doesn't pick it up (I am removing .zcompdump and then restarting zsh to test). This output is interesting: % _gbp zsh: command not found: _gbp % autoload -U _gbp % _gbp zsh: _gbp: function definition file not found Interestingly enough, if I do: % sudo ln -s ~/.zsh/functions/_gbp /usr/share/zsh/vendor-completions/_gbp The completion is picked up by the system, and the _gbp function now exists: % _gbp _arguments:comparguments:312: can only be called from completion function _arguments:comparguments:312: can only be called from completion function My fpath is: % echo $fpath ~/.zsh/functions /usr/local/share/zsh/site-functions /usr/share/zsh/vendor-functions /usr/share/zsh/vendor-completions /usr/share/zsh/functions/Calendar /usr/share/zsh/functions/Chpwd /usr/share/zsh/functions/Completion /usr/share/zsh/functions/Completion/AIX /usr/share/zsh/functions/Completion/BSD /usr/share/zsh/functions/Completion/Base /usr/share/zsh/functions/Completion/Cygwin /usr/share/zsh/functions/Completion/Darwin /usr/share/zsh/functions/Completion/Debian /usr/share/zsh/functions/Completion/Linux /usr/share/zsh/functions/Completion/Mandriva /usr/share/zsh/functions/Completion/Redhat /usr/share/zsh/functions/Completion/Solaris /usr/share/zsh/functions/Completion/Unix /usr/share/zsh/functions/Completion/X /usr/share/zsh/functions/Completion/Zsh /usr/share/zsh/functions/Completion/openSUSE /usr/share/zsh/functions/Exceptions /usr/share/zsh/functions/MIME /usr/share/zsh/functions/Misc /usr/share/zsh/functions/Newuser /usr/share/zsh/functions/Prompts /usr/share/zsh/functions/TCP /usr/share/zsh/functions/VCS_Info /usr/share/zsh/functions/VCS_Info/Backends /usr/share/zsh/functions/Zftp /usr/share/zsh/functions/Zle My zsh is 5.0.2 on amd64, debian linux. So, the question is: why is the completion function not loaded when on my own defined fpath dir? How can I make zsh load it? I will of course provide any extra info necessary. Please CC me on replies, as I'm not subscribed. -- Saludos, Felipe Sateler