wip: feat: Just use straight.el...
Every Nixy solution I could find or conceive had too many points spread across these various facets: - Flimsy (emacsWithPackagesFromUsePackage) - Inelegant (builtins.exec, manual listings) - Inflexible (emacsWithPackagesFromUsePackage) - Otherwise unergonomic (everything }:D) Straight.el is sufficiently declarative, flexible, and Nix-friendly without blindly bowing down to the imperialist NixOS user. Now, Convenience and ergonomics shan't be forsaken for the dogma that is total Nixation.
This commit is contained in:
@@ -1,6 +1,32 @@
|
||||
;; -*- lexical-binding: t; -*-
|
||||
|
||||
(require 'use-package-ensure)
|
||||
(setq use-package-always-ensure t)
|
||||
(defvar bootstrap-version)
|
||||
|
||||
(use-package evil)
|
||||
(setq straight-base-dir
|
||||
(or (getenv "EMACS_STRAIGHT_BASE_DIR")
|
||||
(error "Cannot initialise straight: $EMACS_STRAIGHT_BASE_DIR is undefined!")))
|
||||
|
||||
(let ((bootstrap-file
|
||||
(file-name-concat straight-base-dir
|
||||
"repos/straight.el/bootstrap.el"))
|
||||
(bootstrap-version 7))
|
||||
(unless (file-exists-p bootstrap-file)
|
||||
(let* ((url "https://raw.githubusercontent.com/radian-software/straight.el/develop/install.el")
|
||||
(url-buffer (url-retrieve-synchronously
|
||||
url 'silent 'inhibit-cookies)))
|
||||
(with-current-buffer url-buffer
|
||||
(goto-char (point-max))
|
||||
(eval-print-last-sexp))))
|
||||
(load bootstrap-file nil 'nomessage))
|
||||
|
||||
(setq straight-use-package-by-default t)
|
||||
|
||||
(use-package evil
|
||||
:init
|
||||
(setq evil-want-minibuffer t)
|
||||
:config
|
||||
(evil-mode 1))
|
||||
|
||||
(use-package which-key
|
||||
:config
|
||||
(which-key-mode 1))
|
||||
|
||||
Reference in New Issue
Block a user