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#74946: [PATCH] * lisp/files.el (auto-mode-alist): Include gdbinit too Date: Fri, 20 Dec 2024 08:46:12 +0200 Message-ID: <86seqikg23.fsf@gnu.org> References: <87frml6pkg.fsf@thaodan.de> <86o718ks3b.fsf@gnu.org> <87frmjtl9f.fsf@> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="15323"; mail-complaints-to="usenet@ciao.gmane.io" Cc: acorallo@gnu.org, stefankangas@gmail.com, 74946@debbugs.gnu.org To: =?UTF-8?Q?Bj=C3=B6rn?= Bidar Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Dec 20 07:47:20 2024 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 1tOWn9-0003qT-Rd for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 20 Dec 2024 07:47:20 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tOWmt-0000yg-TG; Fri, 20 Dec 2024 01:47:04 -0500 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 1tOWms-0000yY-Qy for bug-gnu-emacs@gnu.org; Fri, 20 Dec 2024 01:47:03 -0500 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 1tOWms-0005wq-Hy for bug-gnu-emacs@gnu.org; Fri, 20 Dec 2024 01:47:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-version:References:In-Reply-To:From:Date:To:Subject; bh=0m7NaXFBVO87/8oonRh9gE3XabxkGhZaDqhd6UztPBY=; b=S+99E1erGGE9wLo/9F3Y/NeV3pbujEX+Rudp5edlzSwsI5p8+hFaAOgrpyOdMSRBsXwzbfXPhEPyofBY9hoQw/gZSxptRXmx2X1ulBlY8bJxu5PTe2YDbCptp9Ex5fbS+EBa4HZXbnXRv3h8Q/VmS3Ouxr8L2ETk4hIZk0+CRly13G76GXvHTQ8Sil4AYmxESwwa8WO3Z+H29Hbvp3H7J4yDO5xkEcluKNj3AU0fTUCV99HtG4APw1NgI+kzZBX6j+hLnKJFfH644o2MrG+wtYdNRlD3hrB/C1Bp182UOYZs8Y4f0E5n3yH2mVf7/6MkomCn5OQwU7vGFAIu6zE6Bw==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tOWms-0006kJ-4X for bug-gnu-emacs@gnu.org; Fri, 20 Dec 2024 01:47:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 20 Dec 2024 06:47:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74946 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 74946-submit@debbugs.gnu.org id=B74946.173467718325843 (code B ref 74946); Fri, 20 Dec 2024 06:47:02 +0000 Original-Received: (at 74946) by debbugs.gnu.org; 20 Dec 2024 06:46:23 +0000 Original-Received: from localhost ([127.0.0.1]:41368 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tOWmE-0006il-Se for submit@debbugs.gnu.org; Fri, 20 Dec 2024 01:46:23 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:49384) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tOWmC-0006iX-Fg for 74946@debbugs.gnu.org; Fri, 20 Dec 2024 01:46:21 -0500 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 1tOWm6-0005ss-VD; Fri, 20 Dec 2024 01:46:14 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=0m7NaXFBVO87/8oonRh9gE3XabxkGhZaDqhd6UztPBY=; b=Cd6a5YscRWSp1OuNxqcR RcPUmIH2E4WUOPdVovOkbwcXRzvcSz6QFBKk6vVTPyL703yAcbe4qygFP+zAvWGMsvgbGMueZnLmq /irTK3Nk+3j4zaiT67O4eeWxtwmdCXxJpMfdnyKvLwgZjW9vl8TXvmbv4s6uHmJp4puN7cw5BjxjA PxnMEWaeACD2AbGCFXsWtHs6McrS6rLCynXXGaKJTLM4n1tOS03njlc/oDps5xfwaftd6E6ghkIj3 wRE+Fyg4I0xMN7YfWEGUZRycpWp7ywS+C37/UlYjLYpZKFUbI1Q6SJ66zx2O1zpc5RzTPXiMM2QpI zl8RjEHRTg9rXA==; In-Reply-To: <87frmjtl9f.fsf@> (message from =?UTF-8?Q?Bj=C3=B6rn?= Bidar on Thu, 19 Dec 2024 23:29:00 +0200) 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:297423 Archived-At: > From: Björn Bidar > Cc: Stefan Kangas , 74946@debbugs.gnu.org, > acorallo@gnu.org > Date: Thu, 19 Dec 2024 23:29:00 +0200 > > Eli Zaretskii writes: > > > It looks innocent enough, but at this point I'd like to limit changes > > on the release branch to only really urgent and important ones (or > > documentation). We have lived with this outdated code for several > > years (GDB 11.1 was released in 2022), so this change doesn't look > > urgent to me. > > Not really that urgent but to new users of Emacs it would be > beneficial if things would work out of the box. I thought at first Emacs > just didn't support the file. I understand, but my main worry is the potential unintended consequences. Regexps are tricky, as we all know. > > Btw, if we want to fix this entry, we should perhaps do a more > > thorough job. For example, on my system I have files with the > > following base names: > > > > .gdbinit.in > > .gdbinit > > _gdbinit (for MS-DOS) > > gdb.ini (likewise) > > Is this a gdbinit file? The extension looks off. Yes, gdb.ini is a gdbinit file. But if supporting it is problematic or causes too many complications, I'm okay with not supporting that particular file name. > > gdbinit > > gdbinit.in > > SOMETHING-gdbinit > > .gdbinit.loader > > gdbinit-history.exp (not a GDB init file) > > gdbinit.5 (likewise) > > gdbinit.c (likewise) > > .gdbinit.py.in (likewise) > > > > Should we improve the regexp to DTRT for those additional files, but > > without false positives? > > With Stefan correction all these without extension match. What are the > official extensions? gdbinit.in sounds like a normal extension for > gdbinit template in the source but the others such as gdb.ini look off. So we should at least allow the ".in" extension? Also, note that the current regexp doesn't end with a \\' so it could be a partial match with, say, /foo/bar/gdbinit-but-not-really.