From e018190673fb1600ce2cdf0b2b695da3df16187a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Przemys=C5=82aw=20Kryger?= Date: Wed, 13 Nov 2024 17:34:57 +0000 Subject: [PATCH] [fus] defer t --- modules/init-company.el | 1 + modules/init-docker.el | 1 + modules/init-forge.el | 5 ++++- modules/init-git.el | 2 ++ modules/init-helm-projectile.el | 1 + modules/init-help.el | 1 + modules/init-look-and-feel.el | 4 +++- modules/init-org.el | 9 +++++++++ modules/init-prog-mode.el | 1 + modules/init-projectile.el | 1 + modules/init-rtags-helm.el | 1 + modules/init-rtags.el | 35 +++++++++++++++++++-------------- modules/init-xml.el | 1 + 13 files changed, 46 insertions(+), 17 deletions(-) diff --git a/modules/init-company.el b/modules/init-company.el index 7716d61b..62f98a0b 100644 --- a/modules/init-company.el +++ b/modules/init-company.el @@ -17,6 +17,7 @@ (use-package company :diminish "CA" :after (forge) + :defer t :commands (company-begin-backend company-abort) :init diff --git a/modules/init-docker.el b/modules/init-docker.el index 9e9e7f20..d20e0674 100644 --- a/modules/init-docker.el +++ b/modules/init-docker.el @@ -6,6 +6,7 @@ ;;; Code: (use-package docker + :defer t :bind ("C-c D" . #'docker)) (use-package dockerfile-mode diff --git a/modules/init-forge.el b/modules/init-forge.el index 886f7c3c..88754c14 100644 --- a/modules/init-forge.el +++ b/modules/init-forge.el @@ -23,7 +23,8 @@ (use-package async :autoload (async-inject-variables)) (use-package ghub - :autoload (ghub-graphql)) + :autoload (ghub-graphql) + :defer t) (require 'cl-lib) @@ -51,6 +52,7 @@ :commands (forge-post-submit) :autoload (forge-post-at-point forge-current-topic) + :defer t :init (defun exordium-forge-markdown-preview () @@ -154,6 +156,7 @@ USERNAME, AUTH, and HOST behave as for `ghub-request'." :functions (exordium-forge-cleanup-known-repositories--concat exordium-forge-cleanup-known-repositories--question) :autoload (forge-sql) + :defer t :init (defun exordium-forge-cleanup-known-repositories--question (to-delete &optional number) "Return a question about deletion of up to NUMBER of TO-DELETE repositories. diff --git a/modules/init-git.el b/modules/init-git.el index 2cce8947..a440c97a 100644 --- a/modules/init-git.el +++ b/modules/init-git.el @@ -206,6 +206,7 @@ with `exordium-magit-quit-session'." (use-package smerge-mode :ensure nil + :defer t :bind (:map smerge-mode-map ("C-c ^ d" . #'exordium-smerge-dispatch))) @@ -299,6 +300,7 @@ with `exordium-magit-quit-session'." (use-package ediff :ensure nil + :defer t :functions (exordium-ediff-copy-both-to-C) :autoload (ediff-copy-diff ediff-get-region-contents) diff --git a/modules/init-helm-projectile.el b/modules/init-helm-projectile.el index 7e8b6141..08ec7f35 100644 --- a/modules/init-helm-projectile.el +++ b/modules/init-helm-projectile.el @@ -88,6 +88,7 @@ project's file using completion and show it in another window." (use-package treemacs-projectile :after (projectile) + :defer t :bind (("C-c e" . #'treemacs) ("C-c E" . #'treemacs-projectile))) diff --git a/modules/init-help.el b/modules/init-help.el index 41c6ba2a..7ebf0f6e 100644 --- a/modules/init-help.el +++ b/modules/init-help.el @@ -46,6 +46,7 @@ (help-mode . page-break-lines-mode)) (use-package helpful + :defer t :bind (;; Note that the built-in `describe-function' includes both functions ;; and macros. `helpful-function' is functions only, so we provide diff --git a/modules/init-look-and-feel.el b/modules/init-look-and-feel.el index f006c088..73219e10 100644 --- a/modules/init-look-and-feel.el +++ b/modules/init-look-and-feel.el @@ -242,6 +242,7 @@ Set FONT and SIZE if they are passed as arguments." ;;; Expand region (use-package expand-region + :defer t :bind (("C-=" . #'er/expand-region) ("C-M-=" . #'er/contract-region))) @@ -279,7 +280,8 @@ Set FONT and SIZE if they are passed as arguments." ;; Propose vlf (Very Large File) as a choice when opening large files ;; (otherwise one can open a file using M-x vlf): (use-package vlf-setup - :ensure vlf) + :ensure vlf + :defer t) ;; Remove trailing blanks on save (define-minor-mode delete-trailing-whitespace-mode diff --git a/modules/init-org.el b/modules/init-org.el index 2cf3dcbe..242fb2c3 100644 --- a/modules/init-org.el +++ b/modules/init-org.el @@ -30,6 +30,7 @@ :commands (org-mark-subtree org-display-inline-images org-mode) + :defer t :exordium-force-elpa gnu :mode (("\\.org\\'" . org-mode)) :bind @@ -118,17 +119,20 @@ set to nil." ;;; Show org-mode bullets as UTF-8 characters. (use-package org-superstar :after (org) + :defer t :hook (org-mode . org-superstar-mode)) (use-package ox-html :ensure org + :defer t :after (org) :if (not exordium-org-export-css)) (use-package ox-html :ensure org :after (org) + :defer t :if exordium-org-export-css :custom (org-html-htmlize-output-type 'css @@ -139,25 +143,30 @@ set to nil." (use-package ox-md :ensure org :after (org) + :defer t :if exordium-enable-org-export) (use-package ox-beamer :ensure org :after (org) + :defer t :if exordium-enable-org-export) (use-package ox-odt :ensure org :after (org) + :defer t :if exordium-enable-org-export) (use-package ox-publish :ensure org :after (org) + :defer t :if exordium-enable-org-export) (use-package ox-gfm :after (org) + :defer t :if exordium-enable-org-export) (provide 'init-org) diff --git a/modules/init-prog-mode.el b/modules/init-prog-mode.el index 8651aba2..e73e9a9f 100644 --- a/modules/init-prog-mode.el +++ b/modules/init-prog-mode.el @@ -32,6 +32,7 @@ (use-package flyspell :ensure nil + :defer t :if (eq exordium-spell-check :prog) :diminish 'flyspell-mode :hook diff --git a/modules/init-projectile.el b/modules/init-projectile.el index 4a2fc09f..8125b315 100644 --- a/modules/init-projectile.el +++ b/modules/init-projectile.el @@ -19,6 +19,7 @@ (use-package projectile :diminish + :defer t :bind (:map projectile-command-map ("." . #'helm-projectile-find-file-dwim)) diff --git a/modules/init-rtags-helm.el b/modules/init-rtags-helm.el index bbb5ac8c..677244a5 100644 --- a/modules/init-rtags-helm.el +++ b/modules/init-rtags-helm.el @@ -33,6 +33,7 @@ (helm-flycheck)) (use-package helm-flycheck + :defer t :bind (:map c-mode-base-map ("C-c r r" . #'exordium-helm-flycheck) diff --git a/modules/init-rtags.el b/modules/init-rtags.el index 8ad081fb..4fe1b58b 100644 --- a/modules/init-rtags.el +++ b/modules/init-rtags.el @@ -137,29 +137,34 @@ (require 'cl-lib) (use-package rtags - :autoload (rtags-has-diagnostics)) + :autoload (rtags-has-diagnostics) + :defer t) (pcase exordium-complete-mode (:auto-complete (exordium-require 'init-autocomplete) - (use-package ac-rtags) - (use-package auto-complete-c-headers)) + (use-package ac-rtags + :defer t) + (use-package auto-complete-c-headers + :defer t)) (:company - (use-package company-rtags))) + (use-package company-rtags + :defer t))) ;;; Turn on flycheck support when requested (when (eq exordium-rtags-syntax-checker :flycheck) - (use-package flycheck-rtags - :init - ;; As per: https://github.com/Andersbakken/rtags#rtags-flycheck-integration - (defun exordium--setup-flycheck-rtags () - (flycheck-select-checker 'rtags) - (setq-local flycheck-highlighting-mode nil) - (setq-local flycheck-check-syntax-automatically nil)) - :hook - (c-mode . exordium--setup-flycheck-rtags) - (c++-mode . exordium--setup-flycheck-rtags) - (objc-mode . exordium--setup-flycheck-rtags))) + (use-package flycheck-rtags + :defer t + :init + ;; As per: https://github.com/Andersbakken/rtags#rtags-flycheck-integration + (defun exordium--setup-flycheck-rtags () + (flycheck-select-checker 'rtags) + (setq-local flycheck-highlighting-mode nil) + (setq-local flycheck-check-syntax-automatically nil)) + :hook + (c-mode . exordium--setup-flycheck-rtags) + (c++-mode . exordium--setup-flycheck-rtags) + (objc-mode . exordium--setup-flycheck-rtags))) ;;; Key bindings diff --git a/modules/init-xml.el b/modules/init-xml.el index 675fc746..25afc0fc 100644 --- a/modules/init-xml.el +++ b/modules/init-xml.el @@ -7,6 +7,7 @@ ;;; Code: (use-package nxml-mode :ensure nil + :defer t ;; Automatically close tags when typing