Closed JimMoen closed 5 months ago
Thanks @JimMoen for the diagnostics. I see the same thing with clojure-mode
which derives from prog-mode
. There's no specific indentation offset so this warning pops up on the first edit of every buffer.
I'm going to use your hook idea to avoid seeing the warning, but it would be nice to have an option to turn it off.
@bclark-videra a better hook to disable the warn:
(use-package copilot
:hook
(prog-mode . copilot-mode)
(copilot-mode . (lambda ()
(setq-local copilot--indent-warning-printed-p t))))
I think it makes sense to add a defcustom
setting to disable this warning. It might also be useful to allow the user to customize copilot--indentation-alist
to add indentation values for other modes themselves.
My proposal is:
defcustom
to disable indentation offset warning entirely (instead of reusing a private var).copilot--indentation-alist
public (allow user to customize this, adding presets for other modes).thoughts?
Hi! This is mostly a request for comments, more than an actual issue.
The original
lisp-indent-offset
wasnil
and it works well for many elisp files. Which means that lisp indentation in the default configuration is not expected to be a fixed value. But copilot always warn it.Solution:
I used hook for emacs-lisp-mode:
Question:
Is it possible to provide an option to turn off this warning by default?