Skip to content

Instantly share code, notes, and snippets.

@aodock
Created October 5, 2016 13:04
Show Gist options
  • Save aodock/35f4fdf616e283f318ce28af886227c0 to your computer and use it in GitHub Desktop.
Save aodock/35f4fdf616e283f318ce28af886227c0 to your computer and use it in GitHub Desktop.
emacs conficuration file
(setq frame-title-format "emacs")
(menu-bar-mode -1)
(scroll-bar-mode -1)
(ido-mode)
(show-paren-mode)
(global-hl-line-mode)
(winner-mode t)
(windmove-default-keybindings)
(require 'package)
(add-to-list 'package-archives '("org" . "http://orgmode.org/"))
(add-to-list 'package-archives '("gnu" . "http://elpa.gnu.org/packages/"))
(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/") t)
;(add-to-list 'package-archives '("melpa" . "http://melpa.milkbox.net/packages/") t)
(add-to-list 'package-archives '("marmalade" . "http://marmalade-repo.org/packages/") t)
;(add-to-list 'package-archives '("melpa-stable" . "http://stable.melpa.org/packages/"))
(setq package-enable-at-startup nil)
(package-initialize)
(global-set-key (kbd "M-x") 'smex)
(global-set-key (kbd "C-c C-c M-x") 'execute-extended-command)
(ac-config-default)
(load-theme 'monokai t)
(global-undo-tree-mode)
(global-set-key (kbd "M-/") 'undo-tree-visualize)
(global-set-key (kbd "C-x o") 'switch-window)
(global-set-key (kbd "M-p") 'ace-window)
(setq aw-keys '(?a ?s ?d ?f ?g ?h ?j ?k ?l))
;(global-set-key (kbd "M-g e") 'avy-goto-word-0)
(global-set-key (kbd "C-c ;") 'avy-goto-char)
(global-set-key (kbd "C-c '") 'avy-goto-char-2)
(require 'dirtree)
(require 'evil)
(evil-mode 1)
(add-to-list 'load-path "~/.emacs.d/plugins/evil-org-mode")
(require 'evil-org)
(require 'spaceline-config)
(spaceline-spacemacs-theme)
;(nlinum-mode)
(require 'linum-relative)
;; (linum-on)
;; (global-nlinum-mode t)
(linum-mode)
(linum-relative-global-mode)
(setq linum-relative-current-symbol "")
(setq-default left-fringe-width 10)
(setq-default right-fringe-width 0)
(set-face-attribute 'fringe nil :background "black")
(require 'alpha)
(global-set-key (kbd "M-<f12>") 'transparency-increase)
(global-set-key (kbd "M-<f11>") 'transparency-decrease)
;(cua-mode 1) ; make {copy, cut, paste, undo} have {C-c, C-x, C-v, C-z} keys
(electric-pair-mode 1) ; automatically place close bracket when open is typed
(show-paren-mode 1) ; turn on bracket match highlight
;(recentf-mode 1) ; keep a list of recently opened files
;(desktop-save-mode 1) ; save/restore opened files
;(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
; '(custom-safe-themes (quote ("6c62b1cd715d26eb5aa53843ed9a54fc2b0d7c5e0f5118d4efafa13d7715c56e" default))))
;(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
; )
(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(compilation-message-face (quote default))
'(custom-safe-themes (quote ("6c62b1cd715d26eb5aa53843ed9a54fc2b0d7c5e0f5118d4efafa13d7715c56e" default)))
'(fci-rule-color "#3E3D31")
'(highlight-changes-colors (quote ("#FD5FF0" "#AE81FF")))
'(highlight-tail-colors (quote (("#3E3D31" . 0) ("#67930F" . 20) ("#349B8D" . 30) ("#21889B" . 50) ("#968B26" . 60) ("#A45E0A" . 70) ("#A41F99" . 85) ("#3E3D31" . 100))))
'(magit-diff-use-overlays nil)
'(org-agenda-files (quote ("~/Documents/mine/emorg/test.org")))
'(pos-tip-background-color "#A6E22E")
'(pos-tip-foreground-color "#272822")
'(vc-annotate-background nil)
'(vc-annotate-color-map (quote ((20 . "#F92672") (40 . "#CF4F1F") (60 . "#C26C0F") (80 . "#E6DB74") (100 . "#AB8C00") (120 . "#A18F00") (140 . "#989200") (160 . "#8E9500") (180 . "#A6E22E") (200 . "#729A1E") (220 . "#609C3C") (240 . "#4E9D5B") (260 . "#3C9F79") (280 . "#A1EFE4") (300 . "#299BA6") (320 . "#2896B5") (340 . "#2790C3") (360 . "#66D9EF"))))
'(vc-annotate-very-old-color nil)
'(weechat-color-list (unspecified "#272822" "#3E3D31" "#A20C41" "#F92672" "#67930F" "#A6E22E" "#968B26" "#E6DB74" "#21889B" "#66D9EF" "#A41F99" "#FD5FF0" "#349B8D" "#A1EFE4" "#F8F8F2" "#F8F8F0")))
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(org-table ((t (:foreground "brightcyan")))))
;(add-hook 'python-mode-hook
; (lambda () (setq indent-tabs-mode t)))
;(require 'py-smart-operator)
;(add-hook 'python-mode-hook 'py-smart-operator-mode);
; python-mode
(setq py-install-directory "~/.emacs.d/python-mode-6.0.11")
(add-to-list 'load-path py-install-directory)
(require 'python-mode)
; use IPython
;(setq-default py-shell-name "ipython")
;(setq-default py-which-bufname "IPython")
; use the wx backend, for both mayavi and matplotlib
(setq py-python-command-args
'("--gui=wx" "--pylab=wx" "-colors" "Linux"))
(setq py-force-py-shell-name-p t)
; switch to the interpreter after executing code
(setq py-shell-switch-buffers-on-execute-p t)
(setq py-switch-buffers-on-execute-p t)
; don't split windows
(setq py-split-windows-on-execute-p nil)
; try to automagically figure out indentation
(setq py-smart-indentation t)
;; evil-nerd-commenter
(evilnc-default-hotkeys)
;; elpy - mode-name
(elpy-enable)
;; Fixing keybinding bug for yas-expand in elpy-mode
;; (define-key yas-minor-mode (kbd "C-c k") 'yas-expand)
;; Fixing keybinding bug for i-edit in elpy-mode
;; (define-key global-map (kbd "C-c o") ')
;; use flycheck not flymake with elpy
(when (require 'flycheck nil t)
(setq elpy-modules (delq 'elpy-module-flymake elpy-modules))
(add-hook 'elpy-mode-hook 'flycheck-mode))
;; iedit-mode : simultaneous edit/multicursor/interactive edit
(require 'iedit)
;(defun quit-iedit-mode ()
; "Turn off iedit-mode."
; (interactive)
; (iedit-mode -1)
; (evil-mode 1))
;
;(define-key iedit-mode-keymap (kbd "RET") 'quit-iedit-mode)
;Sr-speedbar
(require 'sr-speedbar)
(global-set-key (kbd "M-s") 'sr-speedbar-toggle)
(setq speedbar-use-images nil)
;Aggressive-indent
(add-hook 'emacs-lisp-mode-hook #'aggressive-indent-mode)
(add-hook 'css-mode-hook #'aggressive-indent-mode)
(global-aggressive-indent-mode 1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment