3 (add-to-list 'default-frame-alist '(width . 120))
4 (add-to-list 'default-frame-alist '(height . 40))
5 (add-to-list 'default-frame-alist '(font . "Source Code Pro for Powerline-12:weight:light" ))
6 (load-theme 'tango-dark)
8 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
9 ;http://y.tsutsumi.io/emacs-from-scratch-part-2-package-management.html
11 (add-to-list 'package-archives
12 '("melpa" . "http://melpa.milkbox.net/packages/") t)
15 (defvar required-packages
21 ) "a list of packages to ensure are installed at launch.")
27 ; method to check if all packages are installed
28 (defun packages-installed-p ()
29 (loop for p in required-packages
30 when (not (package-installed-p p)) do (return nil)
33 ; if not all packages are installed, check one by one and install the missing ones.
34 (unless (packages-installed-p)
35 ; check for new packages (package versions)
36 (message "%s" "Emacs is now refreshing its package database...")
37 (package-refresh-contents)
38 (message "%s" " done.")
39 ; install the missing packages
40 (dolist (p required-packages)
41 (when (not (package-installed-p p))
42 (package-install p))))
43 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
45 (setq fiplr-root-markers '(".git" ".svn" "*.DS_Store"))
46 (setq fiplr-ignored-globs '((directories (".git" ".svn"))
47 (files ("*.jpg" "*.png" "*.zip" "*~" "*.o" ".obj" "*.swp" "*.hg" ".pyc" ".*" ))))
50 (setq mac-right-option-modifier 'control)
52 (global-set-key (kbd "C-x f") 'fiplr-find-file)
57 ;;;;;;;;; helm configuration https://github.com/emacs-helm/helm http://tuhdo.github.io/helm-intro.html
58 (require 'helm-config)
59 (global-set-key (kbd "M-x") 'helm-M-x)
61 (setq helm-M-x-fuzzy-match t)
62 (global-set-key (kbd "C-x b") 'helm-mini)
63 (setq helm-buffers-fuzzy-matching t
64 helm-recentf-fuzzy-match t)
65 (global-set-key (kbd "C-x C-f") 'helm-find-files)
66 (when (executable-find "ack-grep")
67 (setq helm-grep-default-command "ack-grep -Hn --no-group --no-color %e %p %f"
68 helm-grep-default-recurse-command "ack-grep -H --no-group --no-color %e %p %f"))