Various
- firewall rule for VNC for `pc` host - `go-translate` emacs package with custom bindings - `magit-delta` to improve diffs readability with `magit` through `delta` - `fira-code-mode` enabled only in `prog-mode` - `mpv` is spawned by `qutebrowser` without waiting for video being loaded
This commit is contained in:
parent
99cd09401a
commit
6791cb51a2
12 changed files with 64 additions and 10 deletions
|
@ -35,7 +35,7 @@
|
|||
};
|
||||
in
|
||||
with pkgs; [
|
||||
silver-searcher
|
||||
delta
|
||||
fd
|
||||
graphviz-nox
|
||||
hunspell
|
||||
|
@ -47,6 +47,7 @@
|
|||
poppler_utils
|
||||
python3Full
|
||||
rnix-lsp
|
||||
silver-searcher
|
||||
stylish-haskell
|
||||
unzip
|
||||
(
|
||||
|
|
|
@ -10,11 +10,10 @@
|
|||
)
|
||||
|
||||
(use-package fira-code-mode
|
||||
:after all-the-icons
|
||||
;;:custom (fira-code-mode-disabled-ligatures '("x")) ;; List of ligatures to turn off
|
||||
:config (progn
|
||||
(global-fira-code-mode)
|
||||
;;TODO: why a timer is needed? It shouldn't
|
||||
(run-at-time "30 sec" nil #'set-fontset-font t '(#Xe100 . #Xe16f) "Fira Code Symbol")))
|
||||
:config
|
||||
:hook ((prog-mode . (lambda () (progn (fira-code-mode) (set-fontset-font t '(#Xe100 . #Xe16f) "Fira Code Symbol"))))))
|
||||
|
||||
(use-package visual-fill-column
|
||||
:commands (visual-fill-column-mode)
|
||||
|
|
|
@ -2,6 +2,9 @@
|
|||
:bind (("C-x g" . magit-status)
|
||||
("C-x C-g" . magit-status)))
|
||||
|
||||
(use-package magit-delta
|
||||
:hook (magit-mode . magit-delta-mode))
|
||||
|
||||
(use-package transient
|
||||
:defer t
|
||||
:config
|
||||
|
|
34
users/profiles/emacs/emacs.d/config/config-translate.el
Normal file
34
users/profiles/emacs/emacs.d/config/config-translate.el
Normal file
|
@ -0,0 +1,34 @@
|
|||
(use-package go-translate
|
||||
:config
|
||||
(defclass gts-insert-render (gts-render) ())
|
||||
|
||||
(cl-defmethod gts-out ((_ gts-insert-render) task)
|
||||
(deactivate-mark)
|
||||
(insert (oref task result)))
|
||||
|
||||
(setq gts-translate-list '(("it" "en")))
|
||||
(setq gts-default-translator
|
||||
(gts-translator
|
||||
:picker
|
||||
(gts-prompt-picker)
|
||||
:engines
|
||||
(gts-google-engine :parser (gts-google-summary-parser))
|
||||
:render
|
||||
(gts-insert-render)
|
||||
))
|
||||
(defun gts-pop-definition ()
|
||||
(interactive)
|
||||
(gts-translate (gts-translator
|
||||
:picker
|
||||
(gts-noprompt-picker :texter (gts-current-or-selection-texter) :single t)
|
||||
:engines
|
||||
(gts-google-engine)
|
||||
:render
|
||||
(gts-posframe-pop-render)
|
||||
)))
|
||||
|
||||
:bind
|
||||
(("C-c t t" . gts-do-translate)
|
||||
("C-c t p" . gts-pop-definition)))
|
||||
|
||||
(provide 'config-translate)
|
|
@ -27,5 +27,6 @@ Return nil if COMMAND is not found anywhere in `exec-path'."
|
|||
(require 'config-nix)
|
||||
(require 'config-purescript)
|
||||
(require 'config-scad)
|
||||
(require 'config-translate)
|
||||
|
||||
(server-start)
|
||||
|
|
|
@ -8,10 +8,11 @@
|
|||
no = "https://search.nixos.org/options?sort=relevance&type=options&query={}";
|
||||
g = "https://google.com/search?q={}";
|
||||
git = "https://github.com/search?q={}";
|
||||
y = "https://www.youtube.com/results?search_query={}";
|
||||
};
|
||||
keyBindings = {
|
||||
normal = {
|
||||
"<Ctrl-V>" = "spawn mpv {url}";
|
||||
"<Ctrl-V>" = "spawn mpv --force-window=immediate {url}";
|
||||
",l" = ''config-cycle spellcheck.languages [" it-IT "] [" en-US "]'';
|
||||
"<z><l>" = "spawn --userscript qute-pass --dmenu-invocation 'fuzzel -d'";
|
||||
"<z><u><l>" = "spawn --userscript qute-pass --dmenu-invocation 'fuzzel -d' --username-only";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue