From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11785 invoked by alias); 26 Apr 2013 15:36:02 -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: 31337 Received: (qmail 15600 invoked from network); 26 Apr 2013 15:35:48 -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=-1.9 required=5.0 tests=BAYES_00 autolearn=ham version=3.3.2 Received-SPF: none (ns1.primenet.com.au: domain at vinc17.net does not designate permitted sender hosts) Date: Fri, 26 Apr 2013 17:35:46 +0200 From: Vincent Lefevre To: zsh-workers@zsh.org Subject: Re: Subversion completion don't work with UTF8 (and other) file names Message-ID: <20130426153546.GV16210@xvii.vinc17.org> Mail-Followup-To: zsh-workers@zsh.org References: <20130426123921.GT16210@xvii.vinc17.org> <20130426154427.06972873@pwslap01u.europe.root.pri> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20130426154427.06972873@pwslap01u.europe.root.pri> X-Mailer-Info: http://www.vinc17.net/mutt/ User-Agent: Mutt/1.5.21-6305-vl-r59709 (2013-04-16) On 2013-04-26 15:44:27 +0100, Peter Stephenson wrote: > Unsetting all the LC_* variables (including LC_ALL) and setting only > LC_CTYPE and LANG should be good enough, shouldn't it? Something like: > > _comp_locale() { > # This exports new locale settings, so should only > # be run in a subshell. A typical use is in a $(...). > local ctype=${${(f)"$(locale 2>/dev/null)"}:#^LC_CTYPE=*} > unset -m LC_\* > [[ -n $ctype ]] && eval export $ctype > export LANG=C > } I think it should work, but these settings should affect only the svn command; I suppose that you need to run that in a subshell. Note that since LC_ALL is unset and LANG is set to C, the LANGUAGE environment variable will be ignored with the GNU libc (so, there is no need to do anything about it). > I've actually lost track of which of the above we're trying to fix up > when we set the locale in this sort of case. LC_COLLATE, certainly, > and I think LC_MESSAGES since otherwise we can't parse it (although > the disadvantage here is the output may be in a language the user > doesn't understand). If this is done only for parsing, the user wouldn't see the message. -- Vincent Lefèvre - Web: 100% accessible validated (X)HTML - Blog: Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)