From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#65120: 29.1; directory-abbrev-alist breaks various things when inside an abbreviated directory Date: Wed, 09 Aug 2023 16:21:46 +0300 Message-ID: <83pm3wl5at.fsf@gnu.org> References: <83leemonyk.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12489"; mail-complaints-to="usenet@ciao.gmane.io" Cc: allred.sean@gmail.com, 65120@debbugs.gnu.org To: Sean Allred Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Aug 09 15:22:20 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1qTj8l-00033l-S0 for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 09 Aug 2023 15:22:20 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qTj8W-0004QX-1P; Wed, 09 Aug 2023 09:22:04 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qTj8U-0004QH-2L for bug-gnu-emacs@gnu.org; Wed, 09 Aug 2023 09:22:02 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qTj8T-00075w-Q3 for bug-gnu-emacs@gnu.org; Wed, 09 Aug 2023 09:22:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qTj8T-0007Td-LM for bug-gnu-emacs@gnu.org; Wed, 09 Aug 2023 09:22:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 09 Aug 2023 13:22:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65120 X-GNU-PR-Package: emacs Original-Received: via spool by 65120-submit@debbugs.gnu.org id=B65120.169158729028690 (code B ref 65120); Wed, 09 Aug 2023 13:22:01 +0000 Original-Received: (at 65120) by debbugs.gnu.org; 9 Aug 2023 13:21:30 +0000 Original-Received: from localhost ([127.0.0.1]:38535 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qTj7x-0007Sg-WA for submit@debbugs.gnu.org; Wed, 09 Aug 2023 09:21:30 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:36420) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qTj7v-0007SN-HO for 65120@debbugs.gnu.org; Wed, 09 Aug 2023 09:21:27 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qTj7q-000707-BL; Wed, 09 Aug 2023 09:21:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=vSIlUeg5TORG+DjZnaPQ0/bUUDVsF71op4bRxyuNmLM=; b=Gk5I4OHSQRkZ JlNvfqXPk8jmcikNqIJ3iIMnbYqzkY9nGUjK6foB0Ei2BTrZLhShgf1fwAuyhDBKG4bTxdzxbkgp/ Obcqe09rRJuIC448XJpyDRRq1icDyenSRoB+Q6vdi4pnzV+t8tW4hjDG9cdrJlW0+uTQivYrsjI0t qC+T8uvQkdLhfzytj6CwhAxsYD5VAhFmP6IQeREEZcWD0tFUlcQwzLqq/R8UBDsu5ilWkSKSdDLj7 l6x5k8IIbKFhL54J2wUsD8y3TrvBK22EEeO4K5NiGUpMAfq3UrcBNdgppsnw5zY/SHw2VevcGss5V 4cclNQfyHeS3VRi9xnxlrQ==; In-Reply-To: (message from Sean Allred on Wed, 09 Aug 2023 06:28:55 -0500) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:267033 Archived-At: > From: Sean Allred > Cc: Sean Allred , 65120@debbugs.gnu.org > Date: Wed, 09 Aug 2023 06:28:55 -0500 > > So, I'd like to shorten this $MegaCorpSource path using built-in > functionality where possible. My users aren't going to care about most > of the path components. I can roll my own, but is there something like > `abbreviate-file-name' that doesn't assume we're working with symlinks? > (Should/could there be? Thoughts on whether or not it is A Good > Idea(tm)?) I don't think there's something in Emacs. But you can use directory-abbrev-alist if you define a drive (using 'subst') that would remove the need for using the full file name. Something like subst x: C:\$MegaCorpSource Then you could use "x:/" in directory-abbrev-alist. This actually matches the "symlink" idea of this feature on Unix. (Yes, I know: corporate IT doesn't like SUBST very much, either. But maybe you will be lucky...)