|
|
|
|
@ -347,70 +347,6 @@ |
|
|
|
|
;; Use system proxy |
|
|
|
|
(setq url-proxy-services '(("http" . "127.0.0.1:8118"))) |
|
|
|
|
#+END_SRC |
|
|
|
|
* Main packages |
|
|
|
|
** Magit |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(global-set-key (kbd "C-x C-g") 'magit-status) |
|
|
|
|
#+END_SRC |
|
|
|
|
** smart-tab |
|
|
|
|
This package is a gem: it allows to make tab work dwim |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(require 'smart-tab) |
|
|
|
|
(global-smart-tab-mode 1) |
|
|
|
|
#+END_SRC |
|
|
|
|
** Outshine |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(require 'outshine) |
|
|
|
|
(add-hook 'outline-minor-mode-hook 'outshine-hook-function) |
|
|
|
|
(setq outshine-use-speed-commands t) |
|
|
|
|
(defvar outline-minor-mode-prefix "\M-#") |
|
|
|
|
(eval-after-load 'outshine '(define-key outline-minor-mode-map (kbd "C-M-i") nil)) |
|
|
|
|
;; (add-hook 'sh-mode-hook 'outline-minor-mode) |
|
|
|
|
#+END_SRC |
|
|
|
|
** helm |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(require 'helm-config) |
|
|
|
|
(helm-mode 1) |
|
|
|
|
(global-set-key (kbd "M-x") 'helm-M-x) |
|
|
|
|
(global-set-key (kbd "C-x C-f") 'helm-find-files) |
|
|
|
|
(global-set-key (kbd "C-x b") 'helm-mini) |
|
|
|
|
(global-set-key (kbd "C-x C-b") 'helm-mini) |
|
|
|
|
(global-set-key (kbd "M-y") 'helm-show-kill-ring) |
|
|
|
|
(define-key helm-map (kbd "C-h") nil) |
|
|
|
|
(define-key helm-find-files-map (kbd "C-h") nil) |
|
|
|
|
(define-key helm-find-files-map (kbd "C-<backspace>") nil) |
|
|
|
|
#+END_SRC |
|
|
|
|
** multiple-cursors |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(require 'multiple-cursors) |
|
|
|
|
(define-key mc/keymap (kbd "<return>") nil) |
|
|
|
|
|
|
|
|
|
(global-set-key (kbd "C->") 'mc/mark-next-like-this) |
|
|
|
|
(global-set-key (kbd "C-<") 'mc/mark-previous-like-this) |
|
|
|
|
(global-set-key (kbd "C-c C-<") 'mc/mark-all-like-this) |
|
|
|
|
|
|
|
|
|
(global-set-key (kbd "C-c <f13>") 'mc/mark-pop) |
|
|
|
|
(global-set-key (kbd "C-c <f14>") 'mc/mark-pop) |
|
|
|
|
#+END_SRC |
|
|
|
|
** avy |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(global-set-key (kbd "C-c SPC") 'avy-goto-word-or-subword-1) |
|
|
|
|
(global-set-key (kbd "M-s") 'avy-goto-word-or-subword-1) |
|
|
|
|
(global-set-key (kbd "M-g M-g") 'avy-goto-line) |
|
|
|
|
(global-set-key (kbd "M-g g") 'avy-goto-line) |
|
|
|
|
#+END_SRC |
|
|
|
|
** expand-region |
|
|
|
|
This is an excellent package, although I do not use it that much |
|
|
|
|
I should find a better binding |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(require 'expand-region) |
|
|
|
|
(global-set-key (kbd "C-=") 'er/expand-region) |
|
|
|
|
#+END_SRC |
|
|
|
|
** Atomic chrome |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
;;(require 'atomic-chrome) |
|
|
|
|
;;(atomic-chrome-start-server) |
|
|
|
|
#+END_SRC |
|
|
|
|
* Settings for important major modes |
|
|
|
|
** TODO split these up and incorporate them in the main file |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
@ -479,6 +415,78 @@ |
|
|
|
|
(emacs-lisp-docstring-fill-column t)) |
|
|
|
|
(fill-paragraph nil region))) |
|
|
|
|
#+END_SRC |
|
|
|
|
* Main packages |
|
|
|
|
** Magit |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(global-set-key (kbd "C-x C-g") 'magit-status) |
|
|
|
|
#+END_SRC |
|
|
|
|
** smart-tab |
|
|
|
|
This package is a gem: it allows to make tab work dwim |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(require 'smart-tab) |
|
|
|
|
(global-smart-tab-mode 1) |
|
|
|
|
#+END_SRC |
|
|
|
|
** Outshine |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(require 'outshine) |
|
|
|
|
(add-hook 'outline-minor-mode-hook 'outshine-hook-function) |
|
|
|
|
(setq outshine-use-speed-commands t) |
|
|
|
|
(defvar outline-minor-mode-prefix "\M-#") |
|
|
|
|
(eval-after-load 'outshine '(define-key outline-minor-mode-map (kbd "C-M-i") nil)) |
|
|
|
|
;; (add-hook 'sh-mode-hook 'outline-minor-mode) |
|
|
|
|
#+END_SRC |
|
|
|
|
** helm |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(require 'helm-config) |
|
|
|
|
(helm-mode 1) |
|
|
|
|
(global-set-key (kbd "M-x") 'helm-M-x) |
|
|
|
|
(global-set-key (kbd "C-x C-f") 'helm-find-files) |
|
|
|
|
(global-set-key (kbd "C-x b") 'helm-mini) |
|
|
|
|
(global-set-key (kbd "C-x C-b") 'helm-mini) |
|
|
|
|
(global-set-key (kbd "M-y") 'helm-show-kill-ring) |
|
|
|
|
(define-key helm-map (kbd "C-h") nil) |
|
|
|
|
(define-key helm-find-files-map (kbd "C-h") nil) |
|
|
|
|
(define-key helm-find-files-map (kbd "C-<backspace>") nil) |
|
|
|
|
#+END_SRC |
|
|
|
|
** multiple-cursors |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(require 'multiple-cursors) |
|
|
|
|
(define-key mc/keymap (kbd "<return>") nil) |
|
|
|
|
|
|
|
|
|
(global-set-key (kbd "C->") 'mc/mark-next-like-this) |
|
|
|
|
(global-set-key (kbd "C-<") 'mc/mark-previous-like-this) |
|
|
|
|
(global-set-key (kbd "C-c C-<") 'mc/mark-all-like-this) |
|
|
|
|
|
|
|
|
|
(global-set-key (kbd "C-c <f13>") 'mc/mark-pop) |
|
|
|
|
(global-set-key (kbd "C-c <f14>") 'mc/mark-pop) |
|
|
|
|
#+END_SRC |
|
|
|
|
** avy |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(global-set-key (kbd "C-c SPC") 'avy-goto-word-or-subword-1) |
|
|
|
|
(global-set-key (kbd "M-s") 'avy-goto-word-or-subword-1) |
|
|
|
|
(global-set-key (kbd "M-g M-g") 'avy-goto-line) |
|
|
|
|
(global-set-key (kbd "M-g g") 'avy-goto-line) |
|
|
|
|
#+END_SRC |
|
|
|
|
** expand-region |
|
|
|
|
This is an excellent package, although I do not use it that much |
|
|
|
|
I should find a better binding |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(require 'expand-region) |
|
|
|
|
(global-set-key (kbd "C-=") 'er/expand-region) |
|
|
|
|
#+END_SRC |
|
|
|
|
** Atomic chrome |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
;;(require 'atomic-chrome) |
|
|
|
|
;;(atomic-chrome-start-server) |
|
|
|
|
#+END_SRC |
|
|
|
|
** Package.el |
|
|
|
|
Load package.el |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(require 'package) |
|
|
|
|
(add-to-list 'package-archives |
|
|
|
|
'("melpa-stable" . "http://stable.melpa.org/packages/") t) |
|
|
|
|
#+END_SRC |
|
|
|
|
|
|
|
|
|
* Tidy-up |
|
|
|
|
** Save emacs-session files in appropriate directory |
|
|
|
|
Save session files to the ~sessions~ directory so that they do not litter |
|
|
|
|
@ -511,12 +519,7 @@ |
|
|
|
|
(face-list)) |
|
|
|
|
#+END_SRC |
|
|
|
|
|
|
|
|
|
* Leftovers |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
;; * toorg |
|
|
|
|
(require 'package) |
|
|
|
|
(add-to-list 'package-archives |
|
|
|
|
'("melpa-stable" . "http://stable.melpa.org/packages/") t) |
|
|
|
|
|
|
|
|
|
** Start server |
|
|
|
|
#+BEGIN_SRC emacs-lisp |
|
|
|
|
(server-start) |
|
|
|
|
#+END_SRC |
|
|
|
|
#+END_SRC |
|
|
|
|
|