unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "João Távora" <joaotavora@gmail.com>
To: Augusto Stoffel <arstoffel@gmail.com>
Cc: 61868@debbugs.gnu.org
Subject: bug#61868: 29.0.60; Eglot: setting "workspace" configurations should be easier
Date: Tue, 28 Feb 2023 19:33:42 +0000	[thread overview]
Message-ID: <87o7pdpotl.fsf@gmail.com> (raw)
In-Reply-To: <878rgiar9o.fsf@gmail.com> (Augusto Stoffel's message of "Tue, 28 Feb 2023 13:49:55 +0100")

Augusto Stoffel <arstoffel@gmail.com> writes:

> I would suggest adding a refined version of this, using a regular buffer
> for input.  Moreover, one could allow editing the configuration as a
> JSON (perhaps also retaining the option to edit as a plist).  This would
> be a natural extension of the existing
> `eglot-show-workspace-configuration' command.

I like this idea.  I agree it's crazy hard to set and get right.  But
this idea needs to be refined indeed.

I'm not crazy about adding this complexity to Eglot, especially because
there's nothing really eglot-specific about it.  It could be used for
any variable you want to add to the current project's root
.dir-locals.el.  But that involves much more consultation in
emacs-devel.

Here's an idea.  Let's make a bare-bones
eglot-show-workspace-configuration that simplifies this 80%.  The other
20% can for later.

In the patch I sent for the other "workspace configuration" bug, the
.dir-locals.el is consulted late (actually it is even now).  So a simple
implementation of eglot-edit-workspace-configuration could be just:

  (defun eglot-edit-workspace-configuration () (interactive)
    (find-file (expand-file-name ".dir-locals.el" (project-root (project-current)))))

My bet is that that two-liner would go a long way.

João





  reply	other threads:[~2023-02-28 19:33 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-28 12:49 bug#61868: 29.0.60; Eglot: setting "workspace" configurations should be easier Augusto Stoffel
2023-02-28 19:33 ` João Távora [this message]
2023-02-28 20:35   ` Augusto Stoffel
2023-02-28 21:16     ` Augusto Stoffel
2023-03-01  2:02     ` João Távora
2023-03-01  7:39       ` Augusto Stoffel
2023-03-01 13:20         ` João Távora

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87o7pdpotl.fsf@gmail.com \
    --to=joaotavora@gmail.com \
    --cc=61868@debbugs.gnu.org \
    --cc=arstoffel@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).