Created
September 25, 2016 09:54
-
-
Save 1buran/b3b71035ec52a63282665d962c3197b6 to your computer and use it in GitHub Desktop.
Emacs config
This file contains hidden or 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
| ;; .emacs -- this is custom Emacs settings file | |
| ;;; Commentary: | |
| ;;; Change Log: | |
| ;;; Code: | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;; Basic Customization ;; | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;; Paths: | |
| (add-to-list 'custom-theme-load-path "~/.emacs.d/themes/") | |
| (let ((default-directory "~/.emacs.d/elpa/")) | |
| (normal-top-level-add-subdirs-to-load-path)) | |
| ;; Package Repositories: | |
| (require 'package) | |
| (add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/")) | |
| (add-to-list 'package-archives '("gnu" . "https://elpa.gnu.org/packages/")) | |
| ;; Enable line numbers: | |
| (global-linum-mode t) | |
| (setq-default linum-format "%4d \u16ca") | |
| ;; Font Settings: | |
| (set-frame-font "Source Code Pro-11") | |
| (setq-default line-spacing 4) | |
| (add-hook 'before-save-hook 'delete-trailing-whitespace) | |
| (blink-cursor-mode 0) | |
| ;; Color Theme: | |
| (load-theme 'tango-plus t) | |
| ;; Disable bars: | |
| (menu-bar-mode -1) | |
| (toggle-scroll-bar -1) | |
| (tool-bar-mode -1) | |
| ;; Disable auto-save mode: | |
| (setq auto-save-default nil) | |
| ;; Frame sizes: | |
| ;; (add-to-list 'default-frame-alist '(height . 58)) | |
| ;; (add-to-list 'default-frame-alist '(width . 88)) | |
| (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 | |
| ("b0ab5c9172ea02fba36b974bbd93bc26e9d26f379c9a29b84903c666a5fde837" "e56ee322c8907feab796a1fb808ceadaab5caba5494a50ee83a13091d5b1a10c" default))) | |
| '(flycheck-status-emoji-mode nil) | |
| '(inhibit-startup-screen t) | |
| '(initial-frame-alist (quote ((fullscreen . maximized)))) | |
| '(package-selected-packages | |
| (quote | |
| (realgud yaml-mode web-mode vlf virtualenvwrapper sphinx-doc neotree markdown-mode json-mode jedi-direx flycheck fill-column-indicator dockerfile-mode auto-complete-rst))) | |
| '(safe-local-variable-values (quote ((engine . django) (encoding . utf-8))))) | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;; Additional plugins ;; | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;; Enable quick file navigation: | |
| (require 'neotree) | |
| (setq neo-smart-open t) | |
| (global-set-key [f8] 'neotree-toggle) | |
| ;; Enable support of Dockerfile syntax hightlight: | |
| (require 'dockerfile-mode) | |
| (add-to-list 'auto-mode-alist '("Dockerfile\\'" . dockerfile-mode)) | |
| ;; Change defauld poor status mode line to much power: | |
| (require 'powerline) | |
| (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. | |
| '(highlight-indentation-current-column-face ((t (:background "rosy brown")))) | |
| '(mode-line ((t (:foreground "#030303" :background "#bdbdbd" :box nil)))) | |
| '(mode-line-inactive ((t (:foreground "#f9f9f9" :background "#666666" :box nil))))) | |
| ;; Enable fill column indicator: | |
| (require 'fill-column-indicator) | |
| (add-hook 'python-mode-hook 'fci-mode) | |
| (setq-default fci-rule-column 79) | |
| ;; Enable support of auto sphinx doc strings: | |
| (add-hook 'python-mode-hook ( | |
| lambda () (require 'sphinx-doc) (sphinx-doc-mode t))) | |
| ;; YAML mode: | |
| (require 'yaml-mode) | |
| (add-to-list 'auto-mode-alist '("\\.yml\\'" . yaml-mode)) | |
| (add-hook 'yaml-mode-hook | |
| '(lambda () | |
| (define-key yaml-mode-map "\C-m" 'newline-and-indent))) | |
| ;; Eclipse’s Alt-Up/Down: | |
| (require 'move-region) | |
| ;; Enable vlf: | |
| (require 'vlf-setup) | |
| ;; Enable ReST and sphinx auto complete: | |
| ;; WARNING: you shoud install pip install jinja2 docutils sphinx | |
| (require 'auto-complete-rst) | |
| (auto-complete-rst-init) | |
| ;; Enable virtualenv: | |
| (require 'virtualenvwrapper) | |
| (venv-initialize-interactive-shells) ;; if you want interactive shell support | |
| (venv-initialize-eshell) ;; if you want eshell support | |
| (setq venv-location "~/envs") | |
| ;; Enable web-mode: | |
| (require 'web-mode) | |
| (add-to-list 'auto-mode-alist '("\\.html?\\'" . web-mode)) | |
| (add-to-list 'auto-mode-alist '("\\.js?\\'" . web-mode)) | |
| (setq web-mode-enable-engine-detection t) | |
| (setq web-mode-code-indent-offset 2) | |
| (setq web-mode-markup-indent-offset 2) | |
| (setq web-mode-css-indent-offset 2) | |
| ;; Enable Jedi: | |
| (setq jedi:setup-keys t) | |
| (add-hook 'python-mode-hook 'jedi:setup) | |
| (setq jedi:complete-on-dot t) ; optional | |
| ;; Enable jedi-direx: | |
| (eval-after-load "python" | |
| '(define-key python-mode-map "\C-cx" 'jedi-direx:pop-to-buffer)) | |
| (add-hook 'jedi-mode-hook 'jedi-direx:setup) | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;; Special Modes ;; | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| (package-initialize) | |
| (global-flycheck-mode) | |
| (ac-config-default) | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;; Auto generated options ;; | |
| ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
| ;;; .emacs ends here | |
| (put 'scroll-left 'disabled nil) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment