summary refs log tree commit diff
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2022-09-17 13:04:38 -0700
committerFranck Cuny <franck@fcuny.net>2022-09-17 13:04:38 -0700
commit69b63f3ac8dab6dd05d7a9db653d2af6732c8175 (patch)
tree0caa5a2651bc5c188b9b960422ce2834886c344d
parentfeat(aspell): more words (diff)
downloademacs.d-69b63f3ac8dab6dd05d7a9db653d2af6732c8175.tar.gz
feat(packages): configure straight for managing packages
straight has a few nice properties:
- reproducible package management
- clone packages to make it easier to work on them when needed
- can use packages that are not in melpa (e.g. other git repositories)

Change-Id: I6a5203bd843e68a040467d63faca8d597150b190
-rw-r--r--emacs/init.el14
1 files changed, 14 insertions, 0 deletions
diff --git a/emacs/init.el b/emacs/init.el
index 727103c..22ffb24 100644
--- a/emacs/init.el
+++ b/emacs/init.el
@@ -88,6 +88,20 @@ Missing packages are installed automatically."
 ;; run package installation
 (my/install-packages)
 
+;; configure straight to manage packages
+(defvar bootstrap-version)
+(let ((bootstrap-file
+      (expand-file-name "straight/repos/straight.el/bootstrap.el" user-emacs-directory))
+      (bootstrap-version 5))
+  (unless (file-exists-p bootstrap-file)
+    (with-current-buffer
+        (url-retrieve-synchronously
+        "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
+        'silent 'inhibit-cookies)
+      (goto-char (point-max))
+      (eval-print-last-sexp)))
+  (load bootstrap-file nil 'nomessage))
+
 (add-to-list 'load-path (expand-file-name "custom/" user-emacs-directory))
 (add-to-list 'load-path (expand-file-name "elisp/" user-emacs-directory))