From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21138 invoked from network); 3 May 1999 00:00:33 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 3 May 1999 00:00:33 -0000 Received: (qmail 19011 invoked by alias); 3 May 1999 00:00:22 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 6185 Received: (qmail 19004 invoked from network); 3 May 1999 00:00:20 -0000 From: "Bart Schaefer" Message-Id: <990502165200.ZM10954@candle.brasslantern.com> Date: Sun, 2 May 1999 16:52:00 -0700 In-Reply-To: <9905021403.AA44254@ibmth.df.unipi.it> Comments: In reply to Peter Stephenson "User installation script for new completion" (May 2, 4:03pm) References: <9905021403.AA44254@ibmth.df.unipi.it> X-Mailer: Z-Mail (4.0b.820 20aug96) To: Peter Stephenson , zsh-workers@sunsite.auc.dk (Zsh hackers list) Subject: Re: User installation script for new completion MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii On May 2, 4:03pm, Peter Stephenson wrote: } Subject: User installation script for new completion } } +# To do: } +# - Maybe this should be sourced, then it can check the user's current } +# setup better. But then there is a potentially horrendous option } +# setting/resetting problem. (Maybe we need another way of doing that.) You don't mean this, do you? typeset -A options options=($(setopt kshoptionprint;setopt)) [[ -o kshoptionprint ]] || options[kshoptionprint]=off [[ -o monitor ]] && options[monitor]=on [[ -o zle ]] && options[zle]=on for i in ${(k)options} do case $options[$i] in on) setopt $i;; off) unsetopt $i;; esac done If you do mean that, then why not have the whole install script be a shell function with "emulate -LR zsh" at the top? The file that you source can define the function and then call it. } +"How would you like the numeric prefix to be treated: } + 0: Not used by correction } + U: Used to given the number of errors } + I: If present, and not 1, do not perform correction? "Used to given the number of errors"?? "give"? "govern"? And what does it do with "the number of errors" once given it? (I know, but presumably a person running this script probably doesn't.) If I were to run compinstall, it would have no effect at all on most of my shells, because my .zshrc exits early by calling 'return' if certain settings are already present in the environment when it runs. I don't have any good suggestions for what to do about this, but I thought I'd mention it anyway. -- Bart Schaefer Brass Lantern Enterprises http://www.well.com/user/barts http://www.brasslantern.com