multi-line my-packages.
This commit is contained in:
parent
155fdef869
commit
9ef2df938e
15
init.el
15
init.el
@ -37,12 +37,19 @@
|
|||||||
'("melpa" . "http://melpa.milkbox.net/packages/") t)
|
'("melpa" . "http://melpa.milkbox.net/packages/") t)
|
||||||
(package-initialize)
|
(package-initialize)
|
||||||
|
|
||||||
(defvar my-packages '(ctags ctags-update evil flymake mo-git-blame multiple-cursors no-easy-keys starter-kit-bindings starter-kit-ruby starter-kit magit ido-ubiquitous find-file-in-project idle-highlight-mode paredit inf-ruby undo-tree rainbow-delimiters)
|
(defvar my-packages '(color-theme ctags ctags-update evil flymake mo-git-blame
|
||||||
"A list of packages to ensure are installed at launch.")
|
multiple-cursors no-easy-keys starter-kit-bindings
|
||||||
|
starter-kit-ruby starter-kit magit ido-ubiquitous
|
||||||
|
find-file-in-project idle-highlight-mode paredit
|
||||||
|
inf-ruby undo-tree rainbow-delimiters smex)
|
||||||
|
"Packages that must be installed at launch.")
|
||||||
|
|
||||||
(defun ensure-package-installed (packages)
|
(defun ensure-package-installed (packages)
|
||||||
"Assure every package is installed, ask for installation if it’s not.
|
"Assure every package is installed, ask for installation if it’s not.
|
||||||
Return a list of installed packages or nil for every package not installed."
|
Return a list of installed packages or nil for every package not installed."
|
||||||
|
;; fetch the list of packages available
|
||||||
|
(unless package-archive-contents
|
||||||
|
(package-refresh-contents))
|
||||||
(mapcar
|
(mapcar
|
||||||
(lambda (package)
|
(lambda (package)
|
||||||
(if (package-installed-p package)
|
(if (package-installed-p package)
|
||||||
@ -51,10 +58,6 @@ Return a list of installed packages or nil for every package not installed."
|
|||||||
(package-install package))))
|
(package-install package))))
|
||||||
packages))
|
packages))
|
||||||
|
|
||||||
;; fetch the list of packages available
|
|
||||||
(unless package-archive-contents
|
|
||||||
(package-refresh-contents))
|
|
||||||
|
|
||||||
(ensure-package-installed my-packages)
|
(ensure-package-installed my-packages)
|
||||||
|
|
||||||
;; =============================================================================
|
;; =============================================================================
|
||||||
|
Loading…
Reference in New Issue
Block a user