From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.devel Subject: Re: New feature in project.el: Remembering the previously used projects Date: Thu, 04 Jun 2020 01:34:12 +0300 Organization: LINKOV.NET Message-ID: <87pnafye1n.fsf@mail.linkov.net> References: <6f0f6cc9-52f4-8383-9827-ead54e898472@yandex.ru> <87pnan8xuf.fsf@tcd.ie> <8834c5e9-90c7-a8ad-3dcd-b8fb95f99df5@yandex.ru> <87eer3nqnd.fsf@warpmail.net> <871rn2ivne.fsf@simenheg@gmail.com> <87367hozkq.fsf@mail.linkov.net> <87a71l2wjf.fsf@simenheg@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="120458"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu) Cc: "Basil L. Contovounesios" , "Philip K." , emacs-devel , Dmitry Gutov To: Simen =?iso-8859-1?Q?Heggest=F8yl?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Jun 04 01:06:22 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jgcSi-000VDc-K1 for ged-emacs-devel@m.gmane-mx.org; Thu, 04 Jun 2020 01:06:20 +0200 Original-Received: from localhost ([::1]:48412 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jgcSh-00081z-Jw for ged-emacs-devel@m.gmane-mx.org; Wed, 03 Jun 2020 19:06:19 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57002) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jgcS3-0006yh-8Y for emacs-devel@gnu.org; Wed, 03 Jun 2020 19:05:39 -0400 Original-Received: from relay6-d.mail.gandi.net ([217.70.183.198]:32829) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jgcS1-0006SD-U4 for emacs-devel@gnu.org; Wed, 03 Jun 2020 19:05:38 -0400 X-Originating-IP: 91.129.108.6 Original-Received: from mail.gandi.net (m91-129-108-6.cust.tele2.ee [91.129.108.6]) (Authenticated sender: juri@linkov.net) by relay6-d.mail.gandi.net (Postfix) with ESMTPSA id 987ADC0008; Wed, 3 Jun 2020 23:05:31 +0000 (UTC) In-Reply-To: <87a71l2wjf.fsf@simenheg@gmail.com> ("Simen =?iso-8859-1?Q?He?= =?iso-8859-1?Q?ggest=F8yl=22's?= message of "Tue, 02 Jun 2020 19:43:32 +0200") Received-SPF: pass client-ip=217.70.183.198; envelope-from=juri@linkov.net; helo=relay6-d.mail.gandi.net X-detected-operating-system: by eggs.gnu.org: First seen = 2020/06/03 18:26:20 X-ACL-Warn: Detected OS = Linux 3.11 and newer X-Spam_score_int: -25 X-Spam_score: -2.6 X-Spam_bar: -- X-Spam_report: (-2.6 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_PASS=-0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:251831 Archived-At: >> Please use a more future-proof format like is used by saveplace.el, >> for example, in ~/.emacs.d/places it's saved as: >> >> ;;; -*- coding: utf-8; mode: lisp-data -*- >> (("/tmp/" >> (dired-filename . "/tmp/file")) >> >> that allows adding more metadata in future. > > Looks good to me. If Dmitry agrees I can start working on changing the > format. While using this new feature, I discovered that switching projects by directory is not quite handy, directory strings are too long and begin with the same prefix. I think there is a need for an additional command to switch projects by name. A clear advantage of Lisp data is that in this case project names could be saved in the same file ~/.emacs.d/projects, e.g.: (("/project/path/" (name . "Project name")) or after implementing the proposal from bug#41572 to use .dir-locals.el, then maybe to save the project name in .dir-locals.el like ((nil . ((project-name . "Project name") A separate question is how to assign a name to a project. > Maybe it should be renamed from "project-list" to simply "projects" too > while we're at it, to match similar files, like "places", "bookmarks", > and so on? Indeed, "projects" is much better. "project-list" looks like that ugly directory name "\Program Files" that caused much trouble to people on MS-Windows whereas it should have been named just "\Programs".