diff --git a/README.md b/README.md index 683c70a..72c4c88 100644 --- a/README.md +++ b/README.md @@ -109,6 +109,32 @@ You can also use the [vim-tab-bar](https://github.com/jamescherti/vim-tab-bar.el (vim-tab-bar-mode 1)) ``` +### How to configure straight.el? + +[Add the straight.el bootstrap code](https://github.com/radian-software/straight.el?tab=readme-ov-file#getting-started) to `~/.emacs.d/pre-init.el`: +``` emacs-lisp +;; Users of Emacs versions >= 27 will want to set +;; package-enable-at-startup to nil +(setq package-enable-at-startup nil) + +;; Straight +(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)) +``` + ## How long does the author's Emacs configuration take to start? The author is using [minimal-emacs.d](https://github.com/jamescherti/minimal-emacs.d) as his `early-init.el` and `init.el`. He is using 152 packages.