feat: Add host sydpc

My, this is a lot TwT.  Much work was batched as part of the transition from
guix-rebound to nixos-testbed/sydpc.

- Discord/Vesktop module & config.
- Syncthing setup.
- Assorted Emacs changes.
- Waybar config.
- Niri config.
- Steam config.
- Some MPD.
- Stylix config.
- Files/Impermanence things.
- Enable Ghostty.
- God knows what else.
This commit is contained in:
Madeleine Sydney
2025-03-17 12:34:26 -06:00
parent 4464e7cec1
commit c48a93ad10
40 changed files with 2632 additions and 179 deletions

View File

@@ -0,0 +1 @@
[cool-deer goes here]

View File

@@ -10,8 +10,11 @@
(setq use-package-compute-statistics t)
(setq gc-cons-threshold
;; (6 gibibytes)
(* 6 (expt 1024 3)))
;; (8 gibibytes)
(* 8 (expt 1024 3)))
(set-frame-parameter nil 'drag-with-header-line t)
(set-frame-parameter nil 'undecorated t)
;; By default, Emacs will cache compilation artifacts in my personal config
;; directory — I'm not keen on that! Redirect it to a dedicated cache directory.

View File

@@ -0,0 +1,9 @@
;;; syd-lang-kdl.el -*- lexical-binding: t; -*-
(use-package kdl-ts-mode
:mode "\\.kdl\\'"
:straight (:type git
:host github
:repo "dataphract/kdl-ts-mode"))
(provide 'syd-lang-kdl)

View File

@@ -13,8 +13,16 @@
(nix-repl)
(current-buffer))
(evil-define-text-object syd-nix-obj-outer-binding (count _beg _end _type)
"TODO"
:type 'inclusive
(let* ((cleanup-p (memq evil-this-operator '(evil-delete)))
(node (treesit-thing-at-point "binding" "nested")))
(list (treesit-node-start node)
(treesit-node-end node))))
(use-package nix-mode
:mode "\\.nix\\'"
;; :mode "\\.nix\\'"
:init
(add-to-list 'auto-mode-alist
(cons (rx "/flake.lock'")
@@ -24,17 +32,30 @@
:config
(add-hook 'nix-mode-hook #'lsp)
(set-popup-rule! (rx bol "*nixos-options-doc*" eol) :ttl 0 :quit t)
(set-repl-handler! 'nix-mode #'syd-nix-open-nix-repl)
(set-repl-handler! '(nix-mode nix-ts-mode) #'syd-nix-open-nix-repl)
(dolist (c '(?- ?_))
(modify-syntax-entry c "w" nix-mode-syntax-table))
;; Inform Smartparens and Evil-surround of Nix's alternative string syntax.
(with-eval-after-load 'smartparens
(sp-local-pair 'nix-mode "''" "''"))
(syd-add-hook 'nix-mode-hook
(sp-local-pair '(nix-mode nix-ts-mode) "''" "''"))
(syd-add-hook '(nix-mode-hook nix-ts-mode-hook)
(defun syd-nix--configure-evil-surround-h ()
(with-eval-after-load 'evil-surround
(push '(?Q . ("''" . "''"))
evil-surround-pairs-alist)))))
(use-package nix-ts-mode
:mode "\\.nix\\'"
:config
(require 'nix-mode)
(general-def
:keymaps 'nix-ts-mode-map
:states '(visual operator)
"ad" #'syd-nix-obj-outer-binding)
(syd-add-hook 'nix-ts-mode-hook
(defun syd-nix-set-syntax-table-h ()
"Set the syntax table in `nix-ts-mode' buffers to `nix-mode-syntax-table'."
(set-syntax-table nix-mode-syntax-table))))
(provide 'syd-lang-nix)

View File

@@ -352,14 +352,14 @@ interactive call to `eval-expression' is stored.")
(advice-add #'evil-indent
:around #'syd-evil-dont-move-point-a))
(use-package evil-leap
:hook (on-first-input . evil-leap-mode)
:load-path "/home/crumb/src/evil-leap"
:straight nil
;; :straight (:type git
;; :host gitlab
;; :repo "msyds/evil-leap")
:config
(evil-leap-install-default-keybindings))
;(use-package evil-leap
; :hook (on-first-input . evil-leap-mode)
; :load-path "/home/crumb/src/evil-leap"
; :straight nil
; ;; :straight (:type git
; ;; :host gitlab
; ;; :repo "msyds/evil-leap")
; :config
; (evil-leap-install-default-keybindings))
(provide 'syd-evil)

View File

@@ -2,6 +2,7 @@
(file-name-concat user-emacs-directory "modules" "lang"))
(require 'syd-lang-agda)
(require 'syd-lang-kdl)
(require 'syd-lang-emacs-lisp)
(require 'syd-lang-clojure)
(require 'syd-lang-nix)

View File

@@ -30,7 +30,8 @@
(use-package emacs
:custom ((initial-scratch-message
(with-temp-buffer
(insert-file-contents "/persist/vault/crumb/cool-deer.org")
(insert-file-contents (file-name-concat user-emacs-directory
"cool-deer.org"))
(buffer-string)))
;; Initial major mode for scratch buffer.
(initial-major-mode 'fundamental-mode)