Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
[patch] Useless use of ls
- X-seq: zsh-workers 38514
- From: Matthew Martin <phy1729@xxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: [patch] Useless use of ls
- Date: Wed, 18 May 2016 22:01:35 -0500
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:subject:message-id:mail-followup-to:mime-version :content-disposition:user-agent; bh=XwyMCuwbJxQ3acKwOviuVOCxjM8k7b/KmFjs9mBr2Xc=; b=xMEhnpsh4y5rl4X0rwSvavCgoblYUM91DXJaj2HLkM9d5Jo1kpc0meNDY1THUaI43o 456sIePzE7XDLzeWPLhsEb5idD5e27OS7Lm3FADf5hsb3YvXCHY+U3FQVA4dPiOKXZZf FzeRsuQVGK2o8NXFsuIdboZUNNr7fZX4HOMqggh53VNulyeowdDBzrmRU8Z36w1H9w7H XFSASiP0dZmFylUjXLtLiUt/pVNgq0TnAI1ntjwCe2ZFsRntraL4YJj1wM0rOBkfvj/Y Mn0Gojh/2gIieKW0znAiHD6SGwwnq1PCPo4ogy68u0L3PfkdBvstlsJBHqhi1z5LrXdW 8Dcw==
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mail-followup-to: zsh-workers@xxxxxxx
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
diff --git a/Completion/Linux/Command/_vserver b/Completion/Linux/Command/_vserver
index 2401387..36a61c4 100644
--- a/Completion/Linux/Command/_vserver
+++ b/Completion/Linux/Command/_vserver
@@ -95,7 +95,7 @@ _vserver_cache_cfgdir() {
_vserver_cache_vsnames() {
if [[ "$_cache_vserver_vsnames_initialized" != true ]]; then
typeset -ga _cache_vserver_vsnames
- _cache_vserver_vsnames=( $(ls -d $_cache_vserver_cfgdir/*/ | sed -e s,$_cache_vserver_cfgdir,, | tr -d '/') )
+ _cache_vserver_vsnames=( $_cache_vserver_cfgdir/*(/:t) )
_cache_vserver_vsnames_initialized=true
fi
}
Messages sorted by:
Reverse Date,
Date,
Thread,
Author