From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.3 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 2918 invoked from network); 28 Dec 2020 23:02:16 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 28 Dec 2020 23:02:16 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1609196536; b=I37SFLxQN9AwhIK1EDdOSxeaco0tW96uyi7eI+3F5i6+BRwPwJ3dgunUz87XH1tCE+e5gIoWr3 thLxssZEw8GTBIC/Mz3MzBuIWIZ4k3hSk7XSspd+5NQQeruOpbmCvgkbzzfDS14f06lJfd2SrD 72gi8sQFsZOozDUFn/e4vFyfzRDD2RNzYNNOarxei9MgHmxp9S1RH7EBb36GpPVTbcF+RhYLD1 yPaQdIxNY3aecH0c1a5RvXzNAYqg8Eih6kAJP2JhTh8drIxAzJP1JNmZ4NFOuA72MXQcCpiZku ZYsQHhQUwNjEM/yJ7978SmjFXdmCil/l/8JT0yZYnDYF+w==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (lobo.spiegl.de) smtp.remote-ip=164.177.170.82; dmarc=none header.from=spiegl.de; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20200801; t=1609196536; bh=NT6fgUvl14pCtMSGwNbMqv3r2OGNSMxyFM/k6qPNIR4=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:In-Reply-To:Content-Type:MIME-Version:References:Message-ID: Subject:To:From:Date:DKIM-Signature; b=n/KH47PDZzOZkx+JZJtxd3HEoPhPYg5gRBewUjhtxh40c0KHgk0ccx/XXLrLDO/Vr4AGm/mgZF 5+fJ3XFW1Ok1ECrnuMjdpN2OcyoSqtPx68OqOYkSz11IUhUqrQpw4xa4t3LHKb0192kxhzOCLY fNZvGtDyY0NGw6muKTixs+8iaYsU9quo1c7ZV/lCQsOt6hoMSu7eqtGoYSuR21afupTnVfQmHE d3x2xz4/Jwo0BDrCBpxCBLBZWOdF+8osEHwzXgIE9KTMdx2JnBah/VDyW8gKZfgThiiCDcAJAk jhSF75X0+L7InYn0DWJULKCdjz1aRa82jeaZ+4UJKWpIUw==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20200801; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:To:From:Date:Reply-To:Cc: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=r+1PFHPgw4H82qFmRVe7cezy/XUD/BclmdFaeNLtly4=; b=MYLlecZalwdlytHgRfVadRUGHz rTqppOa6NuQuihcyD+hxmC8UK4XamGXdoNxZGDQsk3vlHR3o4zz+ufcKChV72g+QapiohT3960e0E kcUdpqhCM15IAoGip61cKBtOfWrLjZHvB+op47yvQpdzzR/Cd5cFo5CRSO35ARiHtk3bZMfIkAQr4 GHWBweBw6kdAV1LYXCfHoSZiEwhgsysJvQY093JiiCgkwyfmvKN9yadAlVV9LsLyV+nXdZBjnHuwe molXd0EzvmtJfi8bJJQ9cTVfsrV2yQkmcJsoS6GOZzQocX42YTAnOPMs+xDlL3vikVI9JmaJvoVpQ vriN/TNw==; Received: from authenticated user by zero.zsh.org with local id 1ku1Wp-000IMI-SL; Mon, 28 Dec 2020 23:02:15 +0000 Authentication-Results: zsh.org; iprev=pass (lobo.spiegl.de) smtp.remote-ip=164.177.170.82; dmarc=none header.from=spiegl.de; arc=none Received: from lobo.spiegl.de ([164.177.170.82]:51118 helo=mail.spiegl.de) by zero.zsh.org with esmtp id 1ku1T7-000Hsv-Mf; Mon, 28 Dec 2020 22:58:26 +0000 Received: from condor.int.spiegl.de (p5796ae48.dip0.t-ipconnect.de [87.150.174.72]) (Authenticated sender: webmaster@spiegl.de) by mail.spiegl.de (Postfix) with ESMTPA id BFE5F251E469 for ; Mon, 28 Dec 2020 23:58:24 +0100 (CET) Received: by condor.int.spiegl.de (Postfix, from userid 1000) id 8DFF6CC0858; Mon, 28 Dec 2020 23:58:24 +0100 (CET) Date: Mon, 28 Dec 2020 23:58:24 +0100 From: Andy Spiegl To: zsh-users@zsh.org Subject: Re: How to tweak the format of file-list completion? Message-ID: Mail-Followup-To: zsh-users@zsh.org References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-gpg-key: ID C2CB30F0, available on friendly keyservers near you X-gpg-fingerprint: 9051 50B9 13B0 57B9 10FD 48AC 4FA1 209B C2CB 30F0 X-angstklauseln: http://www.heise.de/artikel-archiv/ct/2014/08/136_Angstklauseln Authentication-Results: mail.spiegl.de; auth=pass smtp.auth=webmaster@spiegl.de smtp.mailfrom=zsh.Andy@spiegl.de X-Spamd-Result: default: False [1.00 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM(-0.00)[-0.796,0]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; SUBJECT_ENDS_QUESTION(1.00)[]; ASN(0.00)[asn:3320, ipnet:87.128.0.0/10, country:DE]; MID_RHS_MATCH_FROM(0.00)[]; RCVD_COUNT_TWO(0.00)[2] X-Validation-by: vq@larryv.me X-Seq: 26260 Archived-At: X-Loop: zsh-users@zsh.org Errors-To: zsh-users-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-users-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: Archived-At: On 2020-12-20, 14:21, Bart Schaefer wrote: > For the nonce you will have to copy Completion/Unix/Type/_list_files > into an earlier slot in your $fpath and edit the format string that is > passed to "zstat" Found it, thanks! I changed these two statements: zstat -s -H stat -F "%b %e %H:%M" - "$dir$f" >/dev/null 2>&1 listfiles+=("$stat[mode] ${(l:3:)stat[nlink]} ${(r:8:)stat[uid]} ${(r:8:)stat[gid]} ${(l:8:)stat[size]} $stat[mtime] $f") to zstat -s -H stat -F "%Y-%m-%d %H:%M" - "$dir$f" >/dev/null 2>&1 listfiles+=("$stat[mode] ${(r:8:)stat[uid]} ${(r:8:)stat[gid]} ${(l:10:)stat[size]} $stat[mtime] $f") A lot better now! Does zstat have an option to output the file size in "human readable" format, by any chance? Like "ls -h". > A more complete update would be to permit that format to be assigned > in a zstyle. The question is whether to do it like Very cool! I'd be happy with any of these options. Thanks! Andy -- Every person takes the limits of their own field of vision for the limits of the world. (Arthur Schopenhauer)