Compare commits
5 Commits
6c7a17035e
...
b246c9c1ec
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b246c9c1ec | ||
|
|
3cfc99ad2d | ||
|
|
cbc4564289 | ||
|
|
084387246a | ||
|
|
534752a1c3 |
@@ -479,7 +479,34 @@ Setup prefix for keybindings.
|
|||||||
|
|
||||||
* Flycheck
|
* Flycheck
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
(use-package flycheck)
|
(use-package flycheck
|
||||||
|
:preface
|
||||||
|
(defun mp-flycheck-eldoc (callback &rest _ignored)
|
||||||
|
"Print flycheck messages at point by calling CALLBACK."
|
||||||
|
(when-let ((flycheck-errors (and flycheck-mode (flycheck-overlay-errors-at (point)))))
|
||||||
|
(mapc
|
||||||
|
(lambda (err)
|
||||||
|
(funcall callback
|
||||||
|
(format "%s: %s"
|
||||||
|
(let ((level (flycheck-error-level err)))
|
||||||
|
(pcase level
|
||||||
|
('info (propertize "I" 'face 'flycheck-error-list-info))
|
||||||
|
('error (propertize "E" 'face 'flycheck-error-list-error))
|
||||||
|
('warning (propertize "W" 'face 'flycheck-error-list-warning))
|
||||||
|
(_ level)))
|
||||||
|
(flycheck-error-message err))
|
||||||
|
:thing (or (flycheck-error-id err)
|
||||||
|
(flycheck-error-group err))
|
||||||
|
:face 'font-lock-doc-face))
|
||||||
|
flycheck-errors)))
|
||||||
|
|
||||||
|
(defun mp-flycheck-prefer-eldoc ()
|
||||||
|
(add-hook 'eldoc-documentation-functions #'mp-flycheck-eldoc nil t)
|
||||||
|
(setq eldoc-documentation-strategy 'eldoc-documentation-compose-eagerly)
|
||||||
|
(setq flycheck-display-errors-function nil)
|
||||||
|
(setq flycheck-help-echo-function nil))
|
||||||
|
|
||||||
|
:hook ((flycheck-mode . mp-flycheck-prefer-eldoc)))
|
||||||
|
|
||||||
(use-package flycheck-eglot
|
(use-package flycheck-eglot
|
||||||
:after (flycheck eglot)
|
:after (flycheck eglot)
|
||||||
@@ -503,6 +530,12 @@ Setup prefix for keybindings.
|
|||||||
(add-hook 'before-save-hook #'eglot-format-buffer -10 t))))
|
(add-hook 'before-save-hook #'eglot-format-buffer -10 t))))
|
||||||
|
|
||||||
(use-package eglot
|
(use-package eglot
|
||||||
|
:preface
|
||||||
|
(defun mp-eglot-eldoc ()
|
||||||
|
(setq eldoc-echo-area-use-multiline-p nil)
|
||||||
|
(setq eldoc-documentation-strategy
|
||||||
|
'eldoc-documentation-compose-eagerly))
|
||||||
|
|
||||||
:config
|
:config
|
||||||
(add-to-list 'eglot-server-programs
|
(add-to-list 'eglot-server-programs
|
||||||
'(scala-mode .
|
'(scala-mode .
|
||||||
@@ -523,6 +556,7 @@ Setup prefix for keybindings.
|
|||||||
)
|
)
|
||||||
|
|
||||||
:hook (
|
:hook (
|
||||||
|
(eglot-managed-mode . mp-eglot-eldoc)
|
||||||
(go-mode . eglot-ensure)
|
(go-mode . eglot-ensure)
|
||||||
(go-mode . alex/organize-imports-on-save)
|
(go-mode . alex/organize-imports-on-save)
|
||||||
(go-mode . alex/format-on-save)
|
(go-mode . alex/format-on-save)
|
||||||
@@ -555,13 +589,6 @@ Setup prefix for keybindings.
|
|||||||
:after eglot
|
:after eglot
|
||||||
:config (eglot-booster-mode))
|
:config (eglot-booster-mode))
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
** Eldoc-box
|
|
||||||
#+BEGIN_SRC emacs-lisp
|
|
||||||
(use-package eldoc-box
|
|
||||||
:after eglot
|
|
||||||
:bind (:map eglot-mode-map
|
|
||||||
("M-h" . eldoc-box-help-at-point)))
|
|
||||||
#+END_SRC
|
|
||||||
** Go
|
** Go
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
(use-package go-mode
|
(use-package go-mode
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ in
|
|||||||
|
|
||||||
package = pkgs.go;
|
package = pkgs.go;
|
||||||
env = {
|
env = {
|
||||||
GOPATH = "code/go";
|
GOPATH = "/home/alex/code/go";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -19,12 +19,6 @@
|
|||||||
port = 1122;
|
port = 1122;
|
||||||
};
|
};
|
||||||
|
|
||||||
"andromeda" = {
|
|
||||||
hostname = "andromeda.a2x.se";
|
|
||||||
user = "alex";
|
|
||||||
identityFile = "/home/alex/.ssh/alex.pinwheel-andromeda";
|
|
||||||
};
|
|
||||||
|
|
||||||
"tadpole" = {
|
"tadpole" = {
|
||||||
hostname = "65.21.106.222";
|
hostname = "65.21.106.222";
|
||||||
user = "alex";
|
user = "alex";
|
||||||
@@ -118,19 +112,6 @@
|
|||||||
group = "users";
|
group = "users";
|
||||||
};
|
};
|
||||||
|
|
||||||
"alex.pinwheel-andromeda" = {
|
|
||||||
file = ../../../../secrets/pinwheel/alex.pinwheel-andromeda.age;
|
|
||||||
path = "/home/alex/.ssh/alex.pinwheel-andromeda";
|
|
||||||
owner = "alex";
|
|
||||||
group = "users";
|
|
||||||
};
|
|
||||||
"alex.pinwheel-andromeda.pub" = {
|
|
||||||
file = ../../../../secrets/pinwheel/alex.pinwheel-andromeda.pub.age;
|
|
||||||
path = "/home/alex/.ssh/alex.pinwheel-andromeda.pub";
|
|
||||||
owner = "alex";
|
|
||||||
group = "users";
|
|
||||||
};
|
|
||||||
|
|
||||||
"alex.pinwheel-tadpole" = {
|
"alex.pinwheel-tadpole" = {
|
||||||
file = ../../../../secrets/pinwheel/alex.pinwheel-tadpole.age;
|
file = ../../../../secrets/pinwheel/alex.pinwheel-tadpole.age;
|
||||||
path = "/home/alex/.ssh/alex.pinwheel-tadpole";
|
path = "/home/alex/.ssh/alex.pinwheel-tadpole";
|
||||||
|
|||||||
@@ -26,9 +26,9 @@
|
|||||||
security.sudo.wheelNeedsPassword = false;
|
security.sudo.wheelNeedsPassword = false;
|
||||||
|
|
||||||
virtualisation.vmVariant = {
|
virtualisation.vmVariant = {
|
||||||
# following configuration is added only when building VM with build-vm
|
# following configuration is added only when building VM the *first* time with `build-vm`
|
||||||
virtualisation = {
|
virtualisation = {
|
||||||
diskSize = 4096;
|
diskSize = 8192;
|
||||||
memorySize = 2048;
|
memorySize = 2048;
|
||||||
cores = 3;
|
cores = 3;
|
||||||
graphics = false;
|
graphics = false;
|
||||||
|
|||||||
@@ -17,8 +17,6 @@ in {
|
|||||||
"pinwheel/alex.pinwheel-tadpole.pub.age".publicKeys = [ pinwheel tadpole alex ];
|
"pinwheel/alex.pinwheel-tadpole.pub.age".publicKeys = [ pinwheel tadpole alex ];
|
||||||
"pinwheel/alex.pinwheel-github.com.age".publicKeys = [ pinwheel alex ];
|
"pinwheel/alex.pinwheel-github.com.age".publicKeys = [ pinwheel alex ];
|
||||||
"pinwheel/alex.pinwheel-github.com.pub.age".publicKeys = [ pinwheel alex ];
|
"pinwheel/alex.pinwheel-github.com.pub.age".publicKeys = [ pinwheel alex ];
|
||||||
"pinwheel/alex.pinwheel-andromeda.age".publicKeys = [ pinwheel alex ];
|
|
||||||
"pinwheel/alex.pinwheel-andromeda.pub.age".publicKeys = [ pinwheel alex ];
|
|
||||||
"pinwheel/alex.pinwheel-codeberg.org.age".publicKeys = [ pinwheel alex ];
|
"pinwheel/alex.pinwheel-codeberg.org.age".publicKeys = [ pinwheel alex ];
|
||||||
"pinwheel/alex.pinwheel-codeberg.org.pub.age".publicKeys = [ pinwheel alex ];
|
"pinwheel/alex.pinwheel-codeberg.org.pub.age".publicKeys = [ pinwheel alex ];
|
||||||
"pinwheel/alex.pinwheel-git.ppp.pm.age".publicKeys = [ pinwheel alex ];
|
"pinwheel/alex.pinwheel-git.ppp.pm.age".publicKeys = [ pinwheel alex ];
|
||||||
|
|||||||
Reference in New Issue
Block a user