Last active
August 29, 2015 13:55
-
-
Save sabof/8757983 to your computer and use it in GitHub Desktop.
.emacs bootstrap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(set-language-environment "UTF-8") | |
(when (eq system-type 'windows-nt) | |
(setq default-file-name-coding-system 'cp1251)) | |
(defun es-emacs-path (&optional path) | |
(concat (expand-file-name user-emacs-directory) | |
path)) | |
(defun es-org-path (&optional path) | |
(concat (expand-file-name "~/org/") path)) | |
(require 'cl-lib) | |
(defvar es-setup-type | |
(cond (t 'home))) | |
(defmacro es-setup (&rest clauses) | |
`(cl-case es-setup-type | |
,@clauses)) | |
(put 'es-setup 'common-lisp-indent-function | |
'(2 2 &body)) | |
(progn ; LOAD PATH | |
(let ((default-directory (es-emacs-path "site-lisp/"))) | |
(normal-top-level-add-subdirs-to-load-path) | |
(normal-top-level-add-to-load-path | |
(list (es-emacs-path "site-lisp/") | |
(es-emacs-path "") | |
;; "ess/lisp" | |
))) | |
(let ((default-directory (es-emacs-path "site-lisp/packages/"))) | |
(normal-top-level-add-subdirs-to-load-path)) | |
(let ((default-directory (es-emacs-path "site-lisp/settings/"))) | |
(normal-top-level-add-subdirs-to-load-path))) | |
(progn ; PACKAGE | |
(setq yas-snippet-dirs (es-emacs-path "site-lisp/settings/yasnippets/")) | |
(require 'package) | |
(setq package-user-dir (es-emacs-path "elpa/")) | |
(package-initialize) | |
(setq package-enable-at-startup nil | |
package-archives | |
'(("ELPA" . "http://tromey.com/elpa/") | |
("gnu" . "http://elpa.gnu.org/packages/") | |
("melpa" . "http://melpa.milkbox.net/packages/") | |
("marmalade" . "http://marmalade-repo.org/packages/") | |
))) | |
(let* (( package-dependancies | |
'(web-mode | |
smex | |
smartparens | |
skewer-mode | |
sass-mode | |
zencoding-mode | |
yasnippet | |
wgrep-ack | |
web-beautify | |
undo-tree | |
speck | |
scss-mode | |
rainbow-mode | |
paredit | |
multiple-cursors | |
magit ; Last known good version: 20130810.1119 | |
less-css-mode | |
iedit | |
highlight-symbol | |
helm | |
git-gutter-fringe | |
git-gutter | |
expand-region | |
bm | |
auto-complete | |
ack-and-a-half | |
ace-jump-mode | |
nlinum | |
;; Also flx, f3ccfc9 | |
)) | |
( not-installed | |
(cl-remove-if 'package-installed-p | |
package-dependancies))) | |
(when not-installed | |
(package-refresh-contents) | |
(mapc 'package-install not-installed))) | |
(progn ; CUSTOM/THEMES | |
(require 'es-lib nil t) | |
(require 'es-functions nil t) | |
(require 'stripe-buffer nil t) | |
(require 'php-dark-bg nil t) | |
(require 'es-lorem-ipsum nil t) | |
(add-to-list 'custom-theme-load-path | |
(es-emacs-path "elpa/tron-theme-12/")) | |
(add-to-list 'custom-theme-load-path | |
(es-emacs-path "site-lisp/emacs-soothe-theme/")) | |
(require 'dired) | |
(es-setup | |
( home (load-theme 'birds-of-paradise-plus t))) | |
(setq custom-file (es-emacs-path "site-lisp/settings/custom.el")) | |
(load custom-file 'noerror)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment