浏览代码

add c++, spell

Josh Bicking 6 天之前
父节点
当前提交
5d2703f535
共有 2 个文件被更改,包括 20 次插入1 次删除
  1. 18 0
      doom/.config/doom/config.el
  2. 2 1
      doom/.config/doom/init.el

+ 18 - 0
doom/.config/doom/config.el

@@ -81,3 +81,21 @@
   (setq ellama-major-mode #'markdown-mode)
   )
 
+;; Generate an empty personal dictionary
+;; echo YXNwZWxsIGRlZmF1bHQgc3BlbGxlciByb3dsIDEuMTAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAE5hvAAAAAAAAAAAAAAAAAAAAAAAsAAAAIAAAAAAAAAAEAAAACAAAAAwAAAAAAAAABMAAAAAAAAAAQAAAAMAAAAHAAAABAAAAAgAAAAAAAAAAAAAACBlbgBwaG9uZXQAMS4xAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD/////////////////////////////////////////////////////////////////////////////////////////////////////AAAAAAo= | base64 -d > ~/.aspell.en.pws
+(after! spell-fu
+  (spell-fu-dictionary-add (spell-fu-get-ispell-dictionary "en"))
+  (spell-fu-dictionary-add
+   (spell-fu-get-personal-dictionary "en-personal" "~/.aspell.en.pws"))
+  )
+
+
+(after! lsp-mode
+  (defun ak-lsp-ignore-semgrep-rulesRefreshed (workspace notification)
+    "Ignore semgrep/rulesRefreshed notification."
+    (when (equal (gethash "method" notification) "semgrep/rulesRefreshed")
+      (lsp--info "Ignored semgrep/rulesRefreshed notification")
+      t)) ;; Return t to indicate the notification is handled
+
+  (advice-add 'lsp--on-notification :before-until #'ak-lsp-ignore-semgrep-rulesRefreshed)
+  )

+ 2 - 1
doom/.config/doom/init.el

@@ -83,6 +83,7 @@
        :checkers
        syntax              ; tasing you for every semicolon you forget
        ;;(spell +flyspell) ; tasing you for misspelling mispelling
+       spell
        ;;grammar           ; tasing grammar mistake every you make
 
        :tools
@@ -116,7 +117,7 @@
        :lang
        ;;agda              ; types of types of types of types...
        ;;beancount         ; mind the GAAP
-       ;;(cc +lsp)         ; C > C++ == 1
+       (cc +lsp)         ; C > C++ == 1
        ;;clojure           ; java with a lisp
        ;;common-lisp       ; if you've seen one lisp, you've seen them all
        ;;coq               ; proofs-as-programs