From 57d310ed10473ac1c06892f2dc22d6cd25b2291e Mon Sep 17 00:00:00 2001 From: Azat Bahawi Date: Tue, 20 Aug 2024 14:12:44 +0300 Subject: 2024-08-20 --- modules/common/ark.nix | 1 + modules/emacs/default.nix | 2 +- modules/emacs/doom/config.el | 56 ++++++++++++++++++++++++++++---------------- modules/ipfs.nix | 14 +++++++++++ modules/mpv.nix | 2 +- modules/profiles/headful.nix | 2 +- 6 files changed, 54 insertions(+), 23 deletions(-) (limited to 'modules') diff --git a/modules/common/ark.nix b/modules/common/ark.nix index 84ff6db..1e43ef8 100644 --- a/modules/common/ark.nix +++ b/modules/common/ark.nix @@ -45,6 +45,7 @@ in environment.persistence.${cfg.path} = { hideMounts = true; enableDebugging = false; + enableWarnings = false; inherit (cfg) directories files; }; diff --git a/modules/emacs/default.nix b/modules/emacs/default.nix index 1e575ed..eccf179 100644 --- a/modules/emacs/default.nix +++ b/modules/emacs/default.nix @@ -121,7 +121,7 @@ in languagetool # :checkers grammar libxml2 # :lang data :editor format markdownlint-cli # :lang markdown - nil # :lang (nix +lsp) + nixd # :lang (nix +lsp) nixfmt # :lang nix :editor format nls # :lang (nickel +lsp) nodePackages.bash-language-server # :lang (sh +lsp) diff --git a/modules/emacs/doom/config.el b/modules/emacs/doom/config.el index 51d1c47..206e5cd 100644 --- a/modules/emacs/doom/config.el +++ b/modules/emacs/doom/config.el @@ -48,14 +48,27 @@ (setq lsp-enable-suggest-server-download nil lsp-modeline-code-actions-enable nil) +;; +;;; Nix +;; + +(after! nix + (after! lsp-mode + (add-to-list 'lsp-language-id-configuration '(nix-mode . "nix")) + (lsp-register-client (make-lsp-client + :new-connection (lsp-stdio-connection "nixd") + :activation-fn (lsp-activate-on "nix") + :server-id 'nixd + :major-modes 'nix-mode)) + (add-hook 'nix-mode-hook 'lsp-deferred))) + ;; ;;; Go ;; -(setq lsp-go-analyses - '((unsedvariable . t) - (unusedparams . t) - (unusedwrite . t))) +(setq lsp-go-analyses '((unsedvariable . t) + (unusedparams . t) + (unusedwrite . t))) ;; ;;; Org @@ -146,12 +159,12 @@ (use-package! nickel-mode :config (after! lsp-mode - (add-to-list 'lsp-language-id-configuration '(nickel-mode . "nickel") - (lsp-register-client (make-lsp-client - :new-connection (lsp-stdio-connection "nls") - :activation-fn (lsp-activate-on "nickel") - :server-id 'nls - :major-modes 'nickel-mode))) + (add-to-list 'lsp-language-id-configuration '(nickel-mode . "nickel")) + (lsp-register-client (make-lsp-client + :new-connection (lsp-stdio-connection "nls") + :activation-fn (lsp-activate-on "nickel") + :server-id 'nls + :major-modes 'nickel-mode)) (add-hook 'nickel-mode-hook 'lsp-deferred))) ;; @@ -181,16 +194,19 @@ elfeed-goodies/entry-pane-position 'bottom) (add-hook! 'elfeed-new-entry-hook - '((elfeed-make-tagger :before "2 weeks ago" - :remove 'unread) - (elfeed-make-tagger :feed-title "SberMarket Tech" - :entry-title (not ".*(DevOps|Golang).*") - :add 'junk - :remove 'unread) - (elfeed-make-tagger :feed-title "dotconferences" - :entry-title (not ".*dotGo.*") - :add 'junk - :remove 'unread))) + '((elfeed-make-tagger + :before "2 weeks ago" + :remove 'unread) + (elfeed-make-tagger + :feed-title "SberMarket Tech" + :entry-title (not ".*(DevOps|Golang).*") + :add 'junk + :remove 'unread) + (elfeed-make-tagger + :feed-title "dotconferences" + :entry-title (not ".*dotGo.*") + :add 'junk + :remove 'unread))) ;; ;;; mu4e diff --git a/modules/ipfs.nix b/modules/ipfs.nix index 1dad6a6..1e1d23f 100644 --- a/modules/ipfs.nix +++ b/modules/ipfs.nix @@ -115,7 +115,21 @@ in NoAnnounce = filterAddresses; }; + Swarm.AddrFilters = filterAddresses; + + API.HTTPHeaders = { + Access-Control-Allow-Origin = [ + "http://127.0.0.1:5001" + "http://webui.ipfs.io.ipns.localhost:6001" + ]; + Access-Control-Allow-Methods = [ + "PUT" + "POST" + ]; + }; + + Experimental.FilestoreEnabled = true; } ) ]; diff --git a/modules/mpv.nix b/modules/mpv.nix index 467dc94..90d46d9 100644 --- a/modules/mpv.nix +++ b/modules/mpv.nix @@ -103,7 +103,7 @@ in scripts = with pkgs.mpvScripts; [ autoload mpv-cheatsheet - mpv-webm # FIXME https://nixpk.gs/pr-tracker.html?pr=333779 + mpv-webm sponsorblock thumbfast uosc diff --git a/modules/profiles/headful.nix b/modules/profiles/headful.nix index 1b98df0..9f6bff5 100644 --- a/modules/profiles/headful.nix +++ b/modules/profiles/headful.nix @@ -50,7 +50,7 @@ in ''; packages = with pkgs; [ - element-desktop + # element-desktop fd imv libreoffice-fresh -- cgit 1.4.1