diff --git a/modules/config/literate/README.org b/modules/config/literate/README.org index 7a423f7f3..578f4c841 100644 --- a/modules/config/literate/README.org +++ b/modules/config/literate/README.org @@ -74,10 +74,14 @@ For example: (package! other-package) ,#+END_SRC -,#+BEGIN_SRC sh :tangle ~/.dotfiles/bin/script.sh +,#+BEGIN_SRC sh :tangle ~/.dotfiles/bin/script.sh :tangle-mode (identity #o755) #!/usr/bin/env bash echo Hello world ,#+END_SRC + +,#+BEGIN_SRC sh :tangle ~/.dotfiles/bin/script.sh :shebang "#!/usr/bin/env bash" +echo Hello world +,#+END_SRC #+END_SRC ** Modularizing your literate config with ~#+INCLUDE~ directives diff --git a/modules/config/literate/autoload.el b/modules/config/literate/autoload.el index 84c54df38..bc006381a 100644 --- a/modules/config/literate/autoload.el +++ b/modules/config/literate/autoload.el @@ -15,8 +15,8 @@ byte-compiled from.") (print! (start "Compiling your literate config...")) (print-group! (let* ((default-directory doom-private-dir) - (org (expand-file-name +literate-config-file)) - (dest (concat (file-name-sans-extension +literate-config-file) ".el")) + (org (expand-file-name +literate-config-file)) + (dest (concat (file-name-sans-extension +literate-config-file) ".el")) (backup (make-temp-file "config.org.backup"))) (and (require 'ox) (require 'ob-tangle) @@ -24,17 +24,16 @@ byte-compiled from.") (letf! ((defun message (msg &rest args) (when msg (print! (info "%s") (apply #'format msg args)))) - ;; Prevent infinite recursion due to - ;; recompile-on-save hooks later. + ;; Prevent infinite recursion due to recompile-on-save + ;; hooks later. (org-mode-hook nil)) - ;; We do the ol' switcheroo because `org-babel-tangle' - ;; writes changes to the current file, which would be - ;; imposing on the user. + ;; Do the ol' switcheroo because `org-babel-tangle' writes + ;; changes to the user's literate config, which would impose on + ;; the user. (copy-file org backup t) (with-current-buffer (find-file-noselect org) - ;; Tangling doesn't expand #+INCLUDE directives, so we - ;; do it ourselves, since includes are so useful for - ;; literate configs! + ;; Tangling won't ordinarily expand #+INCLUDE directives, so + ;; we do it ourselves. (org-export-expand-include-keyword) (org-babel-tangle nil dest)) t) diff --git a/modules/editor/objed/README.org b/modules/editor/objed/README.org index 88dc60323..3b7af3de9 100644 --- a/modules/editor/objed/README.org +++ b/modules/editor/objed/README.org @@ -11,9 +11,10 @@ This modules adds [[https://github.com/clemera/objed][objed]], a global minor-mo text objects. It combines the ideas of versor-mode and other editors like Vim or Kakoune and tries to align them with regular Emacs conventions. -Note that =objed= is intended as an *alternative* to =evil=, for people who -prefer standard Emacs key-bindings and conventions. It's not recommended to use -these modules together. +#+begin_quote +This module is incompatible with the =:editor evil=. Enabling them both will +cause errors. +#+end_quote [[https://github.com/clemera/objed][See the objed project README]] for information on keybinds and usage. diff --git a/modules/lang/elixir/config.el b/modules/lang/elixir/config.el index 8b5cee237..565e60c65 100644 --- a/modules/lang/elixir/config.el +++ b/modules/lang/elixir/config.el @@ -3,10 +3,6 @@ (after! projectile (add-to-list 'projectile-project-root-files "mix.exs")) -(after! highlight-numbers - (puthash 'elixir-mode - "\\_<-?[[:digit:]]+\\(?:_[[:digit:]]\\{3\\}\\)*\\_>" - highlight-numbers-modelist)) ;; ;;; Packages @@ -41,7 +37,12 @@ (sp-local-pair "fn " " end" :unless '(sp-in-comment-p sp-in-string-p))) (when (featurep! +lsp) - (add-hook 'elixir-mode-local-vars-hook #'lsp!))) + (add-hook 'elixir-mode-local-vars-hook #'lsp!)) + + (after! highlight-numbers + (puthash 'elixir-mode + "\\_<-?[[:digit:]]+\\(?:_[[:digit:]]\\{3\\}\\)*\\_>" + highlight-numbers-modelist))) (use-package! flycheck-credo diff --git a/modules/lang/emacs-lisp/README.org b/modules/lang/emacs-lisp/README.org index a55e124dc..1a127563f 100644 --- a/modules/lang/emacs-lisp/README.org +++ b/modules/lang/emacs-lisp/README.org @@ -43,6 +43,8 @@ This module provides no flags. (in [[file:../../../docs/api.org][docs/api.org]]). + This module extends imenu support for Doom's API (e.g. ~package!~, ~use-package~, ~after!~) ++ Flycheck has been configured to tone down the false positives when you are + editing your Emacs or Doom config. * Prerequisites This module's sole dependency is Emacs. It's very obscure, you wouldn't know diff --git a/modules/lang/emacs-lisp/autoload.el b/modules/lang/emacs-lisp/autoload.el index af8ef16a8..dfa18b64f 100644 --- a/modules/lang/emacs-lisp/autoload.el +++ b/modules/lang/emacs-lisp/autoload.el @@ -222,8 +222,7 @@ verbosity when editing a file in `doom-private-dir' or `doom-emacs-dir'." (or (not default-directory) (cl-find-if (doom-partial #'file-in-directory-p default-directory) +emacs-lisp-disable-flycheck-in-dirs))) - (add-to-list (make-local-variable 'flycheck-disabled-checkers) - 'emacs-lisp-checkdoc) + (add-to-list 'flycheck-disabled-checkers 'emacs-lisp-checkdoc) (set (make-local-variable 'flycheck-emacs-lisp-check-form) (concat "(progn " (prin1-to-string diff --git a/modules/lang/gdscript/config.el b/modules/lang/gdscript/config.el index d27af2e66..3471d4c01 100644 --- a/modules/lang/gdscript/config.el +++ b/modules/lang/gdscript/config.el @@ -12,6 +12,10 @@ :config (set-lookup-handlers! 'gdscript-mode :documentation #'gdscript-docs-browse-symbol-at-point) + + (when (featurep! +lsp) + (add-hook 'gdscript-mode-local-vars-hook #'lsp!)) + (map! :localleader :map gdscript-mode-map @@ -27,7 +31,4 @@ (:prefix ("f" . "format") "b" #'gdscript-format-buffer - "r" #'gdscript-format-region)) - - (when (featurep! +lsp) - (add-hook 'gdscript-mode-local-vars-hook #'lsp!))) + "r" #'gdscript-format-region))) diff --git a/modules/lang/org/contrib/roam.el b/modules/lang/org/contrib/roam.el index 716069e90..abcad2129 100644 --- a/modules/lang/org/contrib/roam.el +++ b/modules/lang/org/contrib/roam.el @@ -37,10 +37,14 @@ :desc "Tomorrow" "m" #'org-roam-dailies-tomorrow :desc "Yesterday" "y" #'org-roam-dailies-yesterday)) :config - (setq org-roam-directory (file-name-as-directory (expand-file-name (or org-roam-directory "roam") - org-directory)) - org-roam-verbose nil ; https://youtu.be/fn4jIlFwuLU - org-roam-buffer-window-parameters '((no-delete-other-windows . t)) ; make org-roam buffer sticky + (setq org-roam-directory + (file-name-as-directory + (expand-file-name (or org-roam-directory "roam") + org-directory)) + org-roam-verbose nil ; https://youtu.be/fn4jIlFwuLU + ;; Make org-roam buffer sticky; i.e. don't replace it when opening a + ;; file with an *-other-window command. + org-roam-buffer-window-parameters '((no-delete-other-windows . t)) org-roam-completion-system (cond ((featurep! :completion helm) 'helm) ((featurep! :completion ivy) 'ivy) diff --git a/modules/lang/php/README.org b/modules/lang/php/README.org index 5ecdbee70..22f7b8f56 100644 --- a/modules/lang/php/README.org +++ b/modules/lang/php/README.org @@ -92,6 +92,7 @@ The features in this module optionally depend on the following php packages: + ~boris~ (REPL) + ~phpctags~ (better code completion) + ~phpunit~ (unit test commands) ++ ~php-cs-fixer~ (for code formatting) #+BEGIN_SRC sh composer global require \ diff --git a/modules/ui/doom/config.el b/modules/ui/doom/config.el index 764b7bfe6..49ecfee84 100644 --- a/modules/ui/doom/config.el +++ b/modules/ui/doom/config.el @@ -35,9 +35,10 @@ (when solaire-global-mode (solaire-global-mode -1)))))) - (add-hook! 'solaire-global-mode-hook + (add-hook! 'solaire-global-mode-hook :append (defun +doom-solaire-swap-bg-faces-maybe-h () - (and solaire-global-mode + (and (bound-and-true-p solaire-global-mode) + (symbolp doom-theme) (string-prefix-p "doom-" (symbol-name doom-theme)) (solaire-mode-swap-bg)))) diff --git a/modules/ui/popup/+hacks.el b/modules/ui/popup/+hacks.el index 7600c2c77..3cfe40144 100644 --- a/modules/ui/popup/+hacks.el +++ b/modules/ui/popup/+hacks.el @@ -364,8 +364,8 @@ Ugh, such an ugly hack." (defadvice! +popup--ignore-window-parameters-a (orig-fn &rest args) "Allow *interactive* window moving commands to traverse popups." :around '(windmove-up windmove-down windmove-left windmove-right) - (letf! ((defun windmove-find-other-window (dir &optional arg window) - (window-in-direction - (pcase dir (`up 'above) (`down 'below) (_ dir)) - window (bound-and-true-p +popup-mode) arg windmove-wrap-around t))) + (letf! (defun windmove-find-other-window (dir &optional arg window) + (window-in-direction + (pcase dir (`up 'above) (`down 'below) (_ dir)) + window (bound-and-true-p +popup-mode) arg windmove-wrap-around t)) (apply orig-fn args)))