3 ms·
I use this in combination with `use-package`. Here's the relevant section copied from my config, copied from right at the top: ;; Straight bootstrap (defv
by matthberg 4y ago
I use this in combination with `use-package`.
Here's the relevant section copied from my config, copied from right at the top:
;; Straight bootstrap
(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))
;; Set up use-package for tidier package configuration/installation
(straight-use-package 'use-package)
(setq straight-use-package-by-default t)
;; Add diminish, which makes it easier to customize lighters (minor mode display)
(use-package diminish)
I use it since it allows for transparent installations, meaning you can find the straight folder (in my case "~/.config/emacs/straight/repos/") and see git repos for all of your installed packages. From there you can edit them, commit to upstream, pull, all of the usual stuff.
Another main reason to use it is that it allows for repeatable installations, something I had struggled with previously with `package.el`. Run `M-x straight-freeze-versions`, and you have a lock file made with the exact commits of all of the dependencies you're running. That way, you don't need to push your entire emacs config folder up to your dotfiles repo, and can get a new install of emacs set up feature-(and bug)-exact on new machines easily.
One gripe I have about it though is that flycheck no longer recognizes `use-package` syntax in my init file and throws a bunch of warnings as a result. If anyone knows a quick fix, please let me know!
- b3n 4y ago> If anyone knows a quick fix, please let me know! I don't use `use-package` (or `flycheck`, what advantage does it have over the built in `flymake`?), but I suspect adding `(require 'use-package)` after `(straight-use-package 'use-package)` would fix it.
- fovc 4y agoNowadays not too much. For a while flymake languished while flycheck got faster, more, robust, added languages, etc. Probably just a function of when op started using Emacs
- morelisp 4y agoNote that "for a while" is in Emacs-time, so we're talking ~2013 to ~2019, i.e. longer than some entire popular editors, that flycheck was the normal way for someone using non-prerelease-Emacs. (And even now I think I'd stick with flycheck if it weren't also for eglot using flymake by default.)