aboutsummaryrefslogtreecommitdiffstats
path: root/modules/init-elpa.el
blob: 16756fe790792908e9dc98990b63b13107f05ee6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
;;; init-elpa.el --- .Emacs Configuration -*- lexical-binding: t -*-
;;; Commentary:
;;

;;; Code:
;;; Find and load the correct package.el
;; =====================================================
;; use-package → https://github.com/jwiegley/use-package
;; =====================================================
(require 'package)

;; Repositories
;; ================
(setq package-archives
      '(("GNU ELPA"     . "https://elpa.gnu.org/packages/")
        ("MELPA Stable" . "https://stable.melpa.org/packages/")
        ("ORG"          . "https://orgmode.org/elpa/")
        ("MELPA"        . "https://melpa.org/packages/"))
      package-archive-priorities
      '(("MELPA Stable" . 10)
        ("GNU ELPA"     . 5)
        ("ORG"          . 3)
        ("MELPA"        . 0))
      package-enable-at-startup nil)
;; =================

(setq package-native-compile t)
(setq package-check-signature 'allow-unsigned)
(setq read-process-output-max (* 1024 1024))
(package-initialize)

(unless (package-installed-p 'use-package)
  (unless (assoc 'melpa package-archives)
    (package-refresh-contents))
  (package-install 'use-package))

(require 'use-package)
(setq use-package-always-ensure t
      use-package-always-defer t
      use-package-compute-statistics t)
;; =====================================================
;; End use-package
;; =====================================================

(provide 'init-elpa)
;; End:
;;; init-elpa.el ends here