diff options
| author | cashmere <cashmere@autistici.org> | 2026-07-12 17:20:18 +0200 |
|---|---|---|
| committer | cashmere <cashmere@autistici.org> | 2026-07-12 17:20:18 +0200 |
| commit | efc8355ca6dbbd8ed44bab4e58c253cc4cbd5a90 (patch) | |
| tree | 3f2bd580e02b8e0116a0e3a75f4433074a4d64df /config.org | |
| parent | 9bffceedcdc1f4c8c0716266e85f24aa8557040b (diff) | |
| download | emacs-efc8355ca6dbbd8ed44bab4e58c253cc4cbd5a90.tar.gz | |
2026-07-12T17:20:20+02:00
Diffstat (limited to 'config.org')
| -rw-r--r-- | config.org | 32 |
1 files changed, 29 insertions, 3 deletions
@@ -178,6 +178,32 @@ Set per-host in the gitignored `local.el'.") :group 'appearance) #+end_src +* freebsd + +Settings that only apply on FreeBSD (system-type = berkeley-unix). +Currently this is only for pinentry-emacs, which is not needed on NixOS. + +#+begin_src emacs-lisp +(when (eq system-type 'berkeley-unix) + ;; Start the Emacs server so emacsclient (and pinentry-emacs) can connect. + (require 'server) + (unless (server-running-p) + (server-start)) + + ;; Handler for pinentry-emacs: GPG passphrase prompts in the minibuffer. + (defun pinentry-emacs (desc prompt _ok _error) + (read-passwd + (concat (replace-regexp-in-string "%22" "\"" + (replace-regexp-in-string "%0A" "\n" desc)) + prompt ": "))) + + ;; Open a file as root via doas. + (defun my/find-file-doas (filename) + "Open FILENAME as root using doas." + (interactive "FFile (with doas): ") + (find-file (concat "/doas::" (expand-file-name filename))))) +#+end_src + * window #+begin_src emacs-lisp @@ -2912,7 +2938,7 @@ BODY is the xonsh script. PARAMS may include :dir and :cmdline." (add-hook 'go-mode-hook #'go-mode-setup)) #+end_src -** json-ts-mode +** COMMENT json-ts-mode #+begin_src emacs-lisp (use-package json-ts-mode @@ -3585,7 +3611,7 @@ created later still get them." #+begin_src emacs-lisp (add-to-list 'custom-theme-load-path "~/.emacs.d/themes/") -(load-theme 'tinty t) +;; (load-theme 'tinty t) #+end_src * dirvish @@ -4214,7 +4240,7 @@ activates automatically. Edit, then `C-c C-c' commits, `C-c C-k' aborts." :wk "find file/switch project") "sp" '(consult-projectile :wk "search project") "ss" '(consult-line :wk "search project") - "sd" '(my/consult-ripgrep-in :wk "grep in dir") + "sg" '(my/consult-ripgrep-in :wk "grep in dir") "sf" '(my/consult-fd-in :wk "find file in dir") "/" '(consult-ripgrep :wk "search project") "." '(find-file :wk "find file") |
