Bohtvaroh

dotemacs

Jul 23rd, 2012
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lisp 4.04 KB | None | 0 0
  1. (custom-set-variables
  2.  ;; custom-set-variables was added by Custom.
  3.  ;; If you edit it by hand, you could mess it up, so be careful.
  4.  ;; Your init file should contain only one such instance.
  5.  ;; If there is more than one, they won't work right.
  6.  '(auto-save-default nil)
  7.  '(backup-inhibited t)
  8.  '(column-number-mode t)
  9.  '(cursor-type (quote bar) t)
  10.  '(default-frame-alist (quote ((top . 200) (left . 1000) (width . 80) (height . 40))))
  11.  '(delete-selection-mode t)
  12.  '(desktop-save-mode t)
  13.  '(icomplete-mode t)
  14.  '(ido-mode t nil (ido))
  15.  '(inhibit-startup-screen t)
  16.  '(initial-scratch-message nil)
  17.  '(kill-do-not-save-duplicates t)
  18.  '(mouse-wheel-follow-mouse 't) ;; scroll window under mouse
  19.  '(mouse-wheel-progressive-speed nil) ;; don't accelerate scrolling
  20.  '(mouse-wheel-scroll-amount '(4 ((shift) . 1))) ;; 3 lines at a time
  21.  '(recentf-mode t)
  22.  '(require-final-newline t)
  23.  '(scroll-preserve-screen-position nil)
  24.  '(scroll-step 1)
  25.  '(set-mark-command-repeat-pop t)
  26.  '(show-paren-mode t)
  27.  '(size-indication-mode)
  28.  '(tool-bar-mode nil)
  29.  '(visible-bell t)
  30.  '(winner-mode t nil (winner)))
  31.  
  32. (custom-set-faces
  33.  ;; custom-set-faces was added by Custom.
  34.  ;; If you edit it by hand, you could mess it up, so be careful.
  35.  ;; Your init file should contain only one such instance.
  36.  ;; If there is more than one, they won't work right.
  37.  '(default ((t (:height 170)))))
  38.  
  39. ;; Package.el customization
  40. (package-initialize)
  41. (add-to-list 'package-archives
  42.              '("melpa" . "http://melpa.milkbox.net/packages/") t)
  43.  
  44. ;; Custom keys
  45. (global-set-key (kbd "<kp-delete>") 'delete-forward-char) ; Apple keyboard
  46. (global-set-key (kbd "C-c C-d") 'kill-whole-line)
  47. (global-set-key (kbd "C-c C-f") 'align-regexp)
  48. (global-set-key (kbd "C-x C-b") 'buffer-menu)
  49. (global-set-key (kbd "M-p") 'scroll-down-line)
  50. (global-set-key (kbd "M-n") 'scroll-up-line)
  51. (global-set-key [f5] 'hl-line-mode)
  52. (global-set-key [f6] 'recentf-open-files)
  53. (global-set-key [f7] 'paredit-mode)
  54. (global-set-key [f8] 'autopair-mode)
  55. (global-set-key [f9] 'nrepl-jack-in)
  56. (global-set-key [f12] 'centered-cursor-mode)
  57. (global-set-key (kbd "C-c M-o") 'erase-buffer)
  58. (global-set-key (kbd "<C-wheel-down>") 'text-scale-decrease)
  59. (global-set-key (kbd "<C-wheel-up>") 'text-scale-increase)
  60. (global-set-key (kbd "M-§") 'next-multiframe-window)
  61. (global-set-key (kbd "C-c SPC") 'ace-jump-mode)
  62. (global-set-key (kbd "C-c SPC") 'ace-jump-mode)
  63. (global-set-key (kbd "C-;") 'ace-jump-line-mode)
  64. (global-set-key (kbd "C-c b") 'nav-toggle)
  65.  
  66. ;; enable disabled commands
  67. (put 'erase-buffer 'disabled nil)
  68. (put 'narrow-to-region 'disabled nil)
  69.  
  70. ;; theme
  71. (when window-system (load-theme 'solarized-light t))
  72.  
  73. ;; delete trailing whitespace on save
  74. (add-hook 'before-save-hook 'delete-trailing-whitespace)
  75.  
  76. ;; save place
  77. (require 'saveplace)
  78. (setq-default save-place t)
  79.  
  80. ;; yes-or-no
  81. (defalias 'yes-or-no-p 'y-or-n-p)
  82.  
  83. ;; centered-cursor-mode
  84. (require 'centered-cursor-mode)
  85.  
  86. ;; emacs-nav
  87. (require 'nav)
  88. (nav-disable-overeager-window-splitting)
  89.  
  90. ;; elscreen
  91. (setq elscreen-display-tab nil)
  92.  
  93. ;; savehist
  94. (savehist-mode t)
  95.  
  96. ;; rainbow delimiters
  97. (global-rainbow-delimiters-mode)
  98.  
  99. ;; Clojure
  100. (add-hook 'clojure-mode-hook 'paredit-mode)
  101.  
  102. ;; nrepl
  103. (add-hook 'nrepl-interaction-mode-hook 'nrepl-turn-on-eldoc-mode)
  104. (add-hook 'nrepl-mode-hook 'paredit-mode)
  105. (setq nrepl-popup-stacktraces nil)
  106. (add-to-list 'same-window-buffer-names "*nrepl*")
  107.  
  108. ;; Auto complete
  109. (require 'auto-complete-config)
  110. (ac-config-default)
  111. (define-key ac-completing-map "\M-/" 'ac-stop)
  112. (setq ac-auto-start 3)
  113. (setq ac-delay 0.75)
  114. (setq ac-auto-show-menu 1.5)
  115. (setq ac-quick-help-delay 2)
  116.  
  117. ;; ac-nrepl
  118. (require 'ac-nrepl)
  119. (add-hook 'nrepl-mode-hook 'ac-nrepl-setup)
  120. (add-hook 'nrepl-interaction-mode-hook 'ac-nrepl-setup)
  121. (eval-after-load "auto-complete" '(add-to-list 'ac-modes 'nrepl-mode))
  122.  
  123. ;; Haskell
  124. (add-hook 'haskell-mode-hook 'turn-on-haskell-doc-mode)
  125. (add-hook 'haskell-mode-hook 'turn-on-haskell-indentation)
  126. (add-hook 'haskell-mode-hook 'paredit-mode)
  127.  
  128. ;; Scala
  129. (add-hook 'scala-mode-hook 'autopair-mode)
Advertisement
Add Comment
Please, Sign In to add comment