Files
.emacs.d/lisp/init-elpa.el
andsy10 b4733718d4 refactor: Reorganize config with use-package and optimize startup hooks
- Split monolithic init-package.el into focused modules
- Convert eager `:init` blocks to lazy `:hook`
- Consolidate UI settings and defer theme loading.
- Remove duplicated config between GUI and terminal paths.
2026-06-04 02:27:20 +08:00

47 lines
1.2 KiB
EmacsLisp
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
;;; init-elpa.el --- elpa config -*- lexical-binding: t -*-
;;; Commentary:
;;; Code:
;; straight.el
(defvar bootstrap-version)
(let ((bootstrap-file
(expand-file-name
"straight/repos/straight.el/bootstrap.el"
(or (bound-and-true-p straight-base-dir)
user-emacs-directory)))
(bootstrap-version 7))
(unless (file-exists-p bootstrap-file)
(with-current-buffer
(url-retrieve-synchronously
"https://raw.githubusercontent.com/radian-software/straight.el/develop/install.el"
'silent 'inhibit-cookies)
(goto-char (point-max))
(eval-print-last-sexp)))
(load bootstrap-file nil 'nomessage))
;; el-patch
(use-package el-patch
:straight t)
;; 从develop分支而不是main分支获取straight.el
(setq straight-repository-branch t)
;; 安装use-packageemacs29以上别装
;; (straight-use-package 'use-package)
;; 配置 use-package
(setq use-package-always-defer t
use-package-expand-minimally t
use-package-verbose t
straight-use-package-version t
straight-use-package-by-default t)
;; 在imenu显示use-package
(setopt use-package-enable-imenu-support t)
(provide 'init-elpa)
;;; init-elpa.el ends here