 ;; Activate installed packages
 (package-initialize)
 
+(defun ensure-package-installed (&rest packages)
+  (mapcar
+  (lambda (package)
+  (if (package-installed-p package)
+     nil
+   (if (y-or-n-p (format "Package %s is missing. Install it? " package))
+       (package-install package)
+     package)))
+  packages))
+
 (ensure-package-installed
  'helm
  'evil
- 'zenburn-theme
- 'color-theme-solarized)
+ 'color-theme-solarized
+ 'sublime-themes
+ 'zenburn-theme)
 
 ;; Required for VIM keybindings
 ;;(require 'evil)

;;(global-linum-mode t)

;; Turn on bracket matching
(show-paren-mode 1)


(require 'package)

(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/"))
(add-to-list 'package-archives '("melpa-stable" . "https://stable.melpa.org/packages/"))
(add-to-list 'package-archives '("marmalade" . "http://marmalade-repo.org/packages/"))

;; Make sure to have downloaded archive description.
(or (file-exists-p package-user-dir)
