From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: John Wiegley Newsgroups: gmane.emacs.devel Subject: Re: Human-readable file sorting Date: Fri, 19 Feb 2016 18:33:26 -0800 Message-ID: References: <87povs41xg.fsf@gnus.org> <87bn7c3yms.fsf@gnus.org> Reply-To: John Wiegley NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1455935722 2268 80.91.229.3 (20 Feb 2016 02:35:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 20 Feb 2016 02:35:22 +0000 (UTC) Cc: emacs-devel@gnu.org To: Lars Ingebrigtsen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Feb 20 03:35:18 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1aWxO9-0006Wm-Hz for ged-emacs-devel@m.gmane.org; Sat, 20 Feb 2016 03:35:17 +0100 Original-Received: from localhost ([::1]:57333 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aWxO9-0001eL-4V for ged-emacs-devel@m.gmane.org; Fri, 19 Feb 2016 21:35:17 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52444) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aWxMe-0007Pa-Qp for emacs-devel@gnu.org; Fri, 19 Feb 2016 21:33:48 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aWxMa-0007bu-Rr for emacs-devel@gnu.org; Fri, 19 Feb 2016 21:33:44 -0500 Original-Received: from mail-pf0-x22a.google.com ([2607:f8b0:400e:c00::22a]:33765) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aWxMa-0007bM-IX for emacs-devel@gnu.org; Fri, 19 Feb 2016 21:33:40 -0500 Original-Received: by mail-pf0-x22a.google.com with SMTP id q63so60659927pfb.0 for ; Fri, 19 Feb 2016 18:33:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:in-reply-to:date:message-id:references :user-agent:reply-to:mail-followup-to:mime-version:content-type; bh=Nb4feeoBAhWBAcKmDgGBz9wjPPhJCWXJhVMYg/QCAlI=; b=xAsQqnLHvPD1tgKJzrUTcc1fLrfajc634mRhhNB55vzz4A3a9qcREZTngmexCRnrW9 26f2bVQ1UxfJyz5zUOOp+MMfSoMdFV5tpoA4CrD3xQd8DWYolqrVaeIP6EZZyCPZVVtK TJEPb/XWFt2Zc86YjsLbW8AxhZ1p/V6DkVy4pH+A/9gWBhixQ+eJyT6TkMf2cXiTuADR qMQebdwdze/I4m2SWRNAd2Da4idfNTfMJF875sklhOgq/8l18FSUkDleRC7B25sUcaFN kVbVUf6nAgthlQ9E1ViMejjZVLm9pvRHTYF+YCKG+ghm6HDXFr3/F2OnYXMQTjy9wJz7 nj9g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:in-reply-to:date:message-id :references:user-agent:reply-to:mail-followup-to:mime-version :content-type; bh=Nb4feeoBAhWBAcKmDgGBz9wjPPhJCWXJhVMYg/QCAlI=; b=h0T3zqFmhnAm4Jz/AF2U9HFW5epO1EH49JkEd/z2q5kRxP7LvcSsEQkCioyy1qMaOS cN5A1G/gjo6Mc+N+yKzBDS9Rmnzj+emjd2b/TqXG74mqsCo/92OgWoNr6VzDIz7v2fzw fDCB9bfMbGhH9VXuHKjLjw263kqzQ2Ym7sdAN2QEsou2+QQ2lvYQ+LHkSpSXRK/V72xT iIj26gUevAMxpOqHFjr2sLf9wyVw8X0v2aR4nch/QcgQ9FKDBZRfrYUOSYXVZjqMceXX bYqUXoFIyFu2QYR6ILvRxfP/QSCpURNSJ+/O9IgA5m8ehpou+4dy/bAfWGFMOkNyZGbE BVXw== X-Gm-Message-State: AG10YORilVyZqevj61L2hIPSqEhdHzjOIji/WA+kWIybbXxXzyYC0HXNISt0VfVuJuSLAg== X-Received: by 10.98.9.129 with SMTP id 1mr22714891pfj.163.1455935617518; Fri, 19 Feb 2016 18:33:37 -0800 (PST) Original-Received: from Vulcan.local (76-234-68-79.lightspeed.frokca.sbcglobal.net. [76.234.68.79]) by smtp.gmail.com with ESMTPSA id xa9sm20690986pab.44.2016.02.19.18.33.31 (version=TLS1 cipher=AES128-SHA bits=128/128); Fri, 19 Feb 2016 18:33:33 -0800 (PST) X-Google-Original-From: "John Wiegley" Original-Received: by Vulcan.local (Postfix, from userid 501) id 7AB8B130D9B99; Fri, 19 Feb 2016 18:33:30 -0800 (PST) In-Reply-To: <87bn7c3yms.fsf@gnus.org> (Lars Ingebrigtsen's message of "Sat, 20 Feb 2016 13:26:51 +1100") User-Agent: Gnus/5.130014 (Ma Gnus v0.14) Emacs/24.5 (darwin) Mail-Followup-To: Lars Ingebrigtsen , emacs-devel@gnu.org X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2607:f8b0:400e:c00::22a X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:200263 Archived-At: >>>>> Lars Ingebrigtsen writes: > The practical way to implement this is to provide a `file-string-lessp' > function that can be configured to sort the way the user prefers, defaulting > to human readable sorting, and then we adjust `directory-files' and other > file-ey commands to call that instead of `string-lessp'. If directory-files were made extensible, so a sorting method could be provided... that sounds like a nice extension to me. So, having a customization variable defaulting to `string-lessp', with an option to switch to `string-human-lessp'. Whether the default should human-lessp is another matter, and something I'd instinctively want to defer until feedback. But having the extensibility does sound nice. -- John Wiegley GPG fingerprint = 4710 CF98 AF9B 327B B80F http://newartisans.com 60E1 46C4 BD1A 7AC1 4BA2