-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinit.el
75 lines (65 loc) · 2.2 KB
/
init.el
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
;; Make availble package functions
(require 'package)
;; add a new package source
(customize-set-variable 'package-archives
(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/")))
;; Initializes package list
(package-initialize)
;; fetch the list of packages available
(unless package-archive-contents
(package-refresh-contents))
;; Only evaluate this when compiling this file
(eval-when-compile
;; For each package on the list do
(dolist (package '(use-package diminish bind-key))
;; Install if not yet installed
(unless (package-installed-p package)
(package-install package))
;; Require package making it available on the rest of the configuration
(require package)))
;; GIT interface for Emacs
(use-package magit
:ensure t
:bind ("C-c m s" . magit-status))
;; Auto-complete interface
(use-package company
:ensure t
:diminish company-mode
:bind ("M-/" . company-complete)
:config
(global-company-mode))
;; Sidebar navigation with extras
(use-package treemacs
:ensure t
:config
(treemacs-filewatch-mode t)
(treemacs-git-mode 'extended)
(treemacs-follow-mode -1)
(add-hook 'treemacs-mode-hook (lambda() (display-line-numbers-mode -1))))
;; Makes treemacs show different colors for committed, staged and modified files
(use-package treemacs-magit
:after (treemacs magit)
:ensure t)
(use-package elixir-mode
:ensure t
:bind (:map elixir-mode-map
("C-c C-f" . elixir-format)))
(setq column-number-mode t)
(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(package-archives
(quote
(("melpa" . "https://melpa.org/packages/")
("gnu" . "https://elpa.gnu.org/packages/"))))
'(package-selected-packages
(quote
(treemacs-magit treemacs company magit diminish use-package))))
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
)