PageRenderTime 19ms CodeModel.GetById 13ms app.highlight 3ms RepoModel.GetById 1ms app.codeStats 0ms

/rejeep-osx.el

http://github.com/rejeep/emacs
Lisp | 40 lines | 19 code | 11 blank | 10 comment | 0 complexity | 6dd6661ff86f6ccbd7951ec410581e73 MD5 | raw file
 1;;; rejeep-osx.el --- OSX specific settings
 2
 3
 4;; Switch the Cmd and Meta keys
 5(setq mac-option-key-is-meta nil)
 6(setq mac-command-key-is-meta t)
 7(setq mac-command-modifier 'meta)
 8(setq mac-option-modifier nil)
 9
10;; Menu bar is not annoying in OSX
11(menu-bar-mode 1)
12
13;; Make Ido ignore freaking .DS_Store files
14(add-to-list 'ido-ignore-files "\\.DS_Store")
15
16;; Make the browser the OS X default
17(setq browse-url-browser-function 'browse-url-default-macosx-browser)
18
19;; In dired, move deletions to trash
20(setq delete-by-moving-to-trash t)
21
22;; Set font
23(set-default-font "-apple-Source_Code_Pro-medium-normal-normal-*-*-*-*-*-m-0-iso10646-1")
24
25(defun finder ()
26  "Opens file directory in Finder."
27  (interactive)
28  (let ((file (buffer-file-name)))
29    (if file
30        (shell-command
31         (format "%s %s" (executable-find "open") (file-name-directory file)))
32      (error "Buffer is not attached to any file."))))
33
34;; Use GNU ls - install with:
35;;    brew install xz
36;;    brew install coreutils
37(setq insert-directory-program "gls")
38
39
40(provide 'rejeep-osx)