summary refs log tree commit diff stats
path: root/emacs
diff options
context:
space:
mode:
authorAlan Pearce2013-05-18 12:35:20 +0100
committerAlan Pearce2013-05-18 12:35:20 +0100
commitc174606193cfead00e88c39f6b96ea8f09fda1ab (patch)
treec756984d642af4f67ef223399db5af45c12a523e /emacs
parent0c6a787848903894cc6ba692c2e93fad83eb4851 (diff)
downloadnixfiles-c174606193cfead00e88c39f6b96ea8f09fda1ab.tar.lz
nixfiles-c174606193cfead00e88c39f6b96ea8f09fda1ab.tar.zst
nixfiles-c174606193cfead00e88c39f6b96ea8f09fda1ab.zip
Emacs: use :ensure to download packages when needed
Diffstat (limited to 'emacs')
-rw-r--r--emacs/init.el40
1 files changed, 19 insertions, 21 deletions
diff --git a/emacs/init.el b/emacs/init.el
index 790c07fc..c298d872 100644
--- a/emacs/init.el
+++ b/emacs/init.el
@@ -55,28 +55,8 @@ Values: `desktop', `server', `laptop'")
 (mapc (lambda (package-name)
         (unless (package-installed-p package-name)
           (package-install package-name)))
-      '(auto-compile
-        auto-indent-mode
-        autopair
-        ace-jump-mode
-        bind-key
-        company
-        dired+
+      '(bind-key
         diminish
-        expand-region
-        helm
-        nginx-mode
-        mic-paren
-        multiple-cursors
-        mustache-mode
-        projectile
-        project-persist
-        paredit
-        solarized-theme
-        smart-tab
-        smart-tabs-mode
-        smex
-        undo-tree
         use-package))
 
 (require 'use-package)
@@ -118,6 +98,7 @@ Values: `desktop', `server', `laptop'")
       jit-lock-defer-time 0.1)
 
 (use-package solarized-theme
+  :ensure t
   :config (load-theme 'solarized-light t))
 
 (when (or (display-graphic-p)
@@ -307,12 +288,14 @@ Values: `desktop', `server', `laptop'")
       completion-ignore-case t)
 
 (use-package smart-tab
+  :ensure t
   :init (global-smart-tab-mode)
   :config (progn
             (nconc smart-tab-completion-functions-alist '((php-mode . php-complete-function)))
             (diminish 'smart-tab-mode "")))
 
 (use-package company
+  :ensure t
   :commands (company-mode)
   :bind (("C-<tab>" . company-complete))
   :init (progn
@@ -332,6 +315,7 @@ Values: `desktop', `server', `laptop'")
 
 (use-package dired+
   :defer t
+  :ensure t
   :config (diredp-toggle-find-file-reuse-dir 1))
 
 ;;;; Documentation
@@ -436,6 +420,7 @@ Values: `desktop', `server', `laptop'")
 
 (use-package auto-indent-mode
   :defer t
+  :ensure t
   :commands (auto-indent-minor-mode
              auto-indent-mode)
   :config (progn
@@ -449,6 +434,7 @@ Values: `desktop', `server', `laptop'")
             (auto-indent-global-mode)))
 
 (use-package smart-tabs-mode
+  :ensure t
   :commands (smart-tabs-mode
              smart-tabs-mode-enable
              smart-tabs-advice)
@@ -493,6 +479,7 @@ Values: `desktop', `server', `laptop'")
   :bind (("M-`" . lacarte-execute-menu-command)))
 
 (use-package helm-config
+  :ensure helm
   :bind (("C-x i"   . helm-imenu)
          ("C-x C-b" . helm-mini)))
 
@@ -511,6 +498,7 @@ Values: `desktop', `server', `laptop'")
             (bind-key "C-c C-s" #'ido-manual-merge ido-file-dir-completion-map)))
 
 (use-package smex
+  :ensure t
   :bind (("M-x" . smex)
          ("<apps>" . smex)
          ("<menu>" . smex)
@@ -627,10 +615,12 @@ Values: `desktop', `server', `laptop'")
 ;;;; Projects
 
 (use-package projectile
+  :ensure t
   :bind (("C-c C-f" . projectile-find-file))
   :commands (projectile-global-mode))
 
 (use-package project-persist
+  :ensure t
   :commands (project-persist-mode)
   :bind (("C-c P d" . project-persist-delete)
          ("C-c P f" . project-persist-find)
@@ -775,6 +765,7 @@ Also returns nil if pid is nil."
   (setq x-select-request-type '(UTF8_STRING COMPOUND_TEXT TEXT STRING)))
 
 (use-package ace-jump-mode
+  :ensure t
   :bind (("C-c SPC" . ace-jump-mode))
   :config (progn
             (ace-jump-mode-enable-mark-sync)
@@ -782,6 +773,7 @@ Also returns nil if pid is nil."
                   ace-jump-mode-scope 'window)))
 
 (use-package autopair
+  :ensure t
   :commands (autopair-mode)
   :init (progn
           (add-hook 'prog-mode-hook #'autopair-mode)
@@ -789,12 +781,14 @@ Also returns nil if pid is nil."
                 autopair-skip-whitespace nil)))
 
 (use-package expand-region
+  :ensure t
   :bind ("C-M-SPC" . er/expand-region))
 
 (use-package goto-chg
   :bind ("C-x C-SPC" . goto-last-change))
 
 (use-package multiple-cursors
+  :ensure t
   :bind (("C-." . mc/mark-next-like-this)
          ("C-," . mc/mark-previous-like-this)
          ("M-<f3>" . mc/mark-all-like-this-dwim)
@@ -802,6 +796,7 @@ Also returns nil if pid is nil."
          ("C-S-L" . mc/edit-lines)))
 
 (use-package paredit
+  :ensure t
   :commands (paredit-mode)
   :init (progn
           (put #'paredit-forward-delete 'delete-selection 'supersede)
@@ -823,6 +818,7 @@ Also returns nil if pid is nil."
          ("C-M-n" . smart-forward)))
 
 (use-package undo-tree
+  :ensure t
   :idle (require 'undo-tree)
   :defer t
   :config (progn
@@ -914,6 +910,7 @@ Also returns nil if pid is nil."
 ;;;; Programming
 
 (use-package auto-compile
+  :ensure t
   :commands (auto-compile-on-save-mode)
   :init (add-hook 'emacs-lisp-mode-hook #'auto-compile-on-save-mode))
 
@@ -1007,6 +1004,7 @@ Works with: arglist-cont-nonempty, arglist-close."
                   js3-curly-indent-offset 4)))
 
 (use-package mustache-mode
+  :ensure t
   :mode (("\\.mustache" . mustache-mode)
          ("\\.mt\\'" . mustache-mode)
          ("\\.template\\'" . mustache-mode)))