From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: A few issues with thumbs.el Date: Sun, 12 Jun 2005 14:03:21 -0400 Message-ID: <877jgz798n.fsf-monnier+emacs@gnu.org> References: <87br6zuerw.fsf-monnier+emacs@gnu.org> <87u0kqrsur.fsf-monnier+emacs@gnu.org> <87hdgon2p2.fsf@jurta.org> <87vf508myc.fsf-monnier+emacs@gnu.org> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1118599307 29374 80.91.229.2 (12 Jun 2005 18:01:47 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 12 Jun 2005 18:01:47 +0000 (UTC) Cc: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Jun 12 20:01:39 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1DhWmA-0006Za-Rw for ged-emacs-devel@m.gmane.org; Sun, 12 Jun 2005 20:01:39 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1DhWqo-0006Gx-0L for ged-emacs-devel@m.gmane.org; Sun, 12 Jun 2005 14:06:26 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1DhWqG-0006AE-78 for emacs-devel@gnu.org; Sun, 12 Jun 2005 14:05:53 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1DhWqC-00066p-1D for emacs-devel@gnu.org; Sun, 12 Jun 2005 14:05:49 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1DhWqB-00065X-4B for emacs-devel@gnu.org; Sun, 12 Jun 2005 14:05:47 -0400 Original-Received: from [209.226.175.34] (helo=tomts13-srv.bellnexxia.net) by monty-python.gnu.org with esmtp (Exim 4.34) id 1DhWoh-0003KM-UN for emacs-devel@gnu.org; Sun, 12 Jun 2005 14:04:16 -0400 Original-Received: from alfajor ([70.48.82.205]) by tomts13-srv.bellnexxia.net (InterMail vM.5.01.06.10 201-253-122-130-110-20040306) with ESMTP id <20050612180321.EOTQ25800.tomts13-srv.bellnexxia.net@alfajor>; Sun, 12 Jun 2005 14:03:21 -0400 Original-Received: by alfajor (Postfix, from userid 1000) id 2C19BD73E6; Sun, 12 Jun 2005 14:03:21 -0400 (EDT) Original-To: Mathias Dahl In-Reply-To: (Mathias Dahl's message of "12 Jun 2005 11:01:18 +0200") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:38656 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:38656 >> - I wish there was a way to put the thumbs directly next to the original >> image files. E.g. instead of ~/.emacs-thumbs/foo!bar!baz!toto!NNNN.jpg >> I'd like to use ~/foo/bar/baz/.emacs-thumbs/toto_NNNN.jpg. > What are the benefits of doing this? Locality. I find the concept of locality to be extremely important. E.g. if I rename the directory "foo/bar/baz" to "off/bar/baz" it will just keep working without any need to recreate thumbs. If I delete the directory, the thumbs will automatically be deleted with the images, ... > I think it would litter the system with extra directories. What are the problems with that? It'll still be a negligible fraction of the disk space and of the number of directories on the disk. Other advantages: the number of files in a .emacs-thumbs dir will this way not be larger than the number of files in any other directory, so it'll automatically avoid suffering from the all-too-common problem where some Unix file systems don't handle large directories efficiently (things like O(n) lookup (and worse) behavior). > I can see how it could solve the uniqueness-problem, not needing to add > a hash anymore, but I don't know how big a problem that is (see discussion > below). I don't care much about solving the uniqueness problem. I just think that putting the thumbs next to their source image is The Right Thing. Stefan