diff options
| author | Miquel Sabaté Solà <msabate@suse.com> | 2019-09-04 11:17:25 +0200 |
|---|---|---|
| committer | Miquel Sabaté Solà <msabate@suse.com> | 2019-09-04 11:17:25 +0200 |
| commit | c28324bae16a71937006c0d8a4f606cdc1eb077c (patch) | |
| tree | 7e14255fbcc993276a47d5c18bdc2b02332b2e05 /.emacs.d/init.org | |
| parent | f08ce606c77bde84cbcc28965c6c5dc218478d1e (diff) | |
| download | dotfiles-c28324bae16a71937006c0d8a4f606cdc1eb077c.tar.gz dotfiles-c28324bae16a71937006c0d8a4f606cdc1eb077c.zip | |
emacs.d: be a bit more careful with versions
Signed-off-by: Miquel Sabaté Solà <msabate@suse.com>
Diffstat (limited to '.emacs.d/init.org')
| -rw-r--r-- | .emacs.d/init.org | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/.emacs.d/init.org b/.emacs.d/init.org index c2c9197..74fc18f 100644 --- a/.emacs.d/init.org +++ b/.emacs.d/init.org @@ -68,8 +68,13 @@ are some exceptions to this (e.g. webkit support), but these cases are individually handled. #+BEGIN_SRC elisp - (unless (>= emacs-major-version 25) - (error "Don't be a cheap bastard and upgrade to at least GNU Emacs 25")) +(let ((minver "25.1") + (recver "26.1")) + (when (version< emacs-version minver) + (error "Don't be a cheap bastard and upgrade to at least GNU Emacs v%s" minver)) + + (when (version< emacs-version recver) + (message "Your GNU Emacs is a bit old and some functionality will be disabled. Consider upgrading to at least v%s" recver))) #+END_SRC Temporarily reduce garbage collection so startup time is lower. Idea taken from @@ -109,7 +114,8 @@ Initialize package. #+BEGIN_SRC elisp (require 'package) -(setq gnutls-algorithm-priority "NORMAL:-VERS-TLS1.3") +(when (version= "26.2" emacs-version) + (setq gnutls-algorithm-priority "NORMAL:-VERS-TLS1.3")) (add-to-list 'package-archives '("melpa" . "http://melpa.milkbox.net/packages/") t) |
