| | |
| | | (use-package projectile |
| | | :ensure t |
| | | :bind ("C-c p" . projectile-command-map) |
| | | :diminish projectile-mode |
| | | :config |
| | | (projectile-global-mode) |
| | | (setq projectile-completion-system 'helm) |
| | |
| | | (find-file "~/.emacs.d/config.org")) |
| | | (global-set-key (kbd "C-c e d") 'config-visit) |
| | | #+END_SRC |
| | | ** Go to init.el |
| | | #+BEGIN_SRC emacs-lisp |
| | | (defun init-visit () |
| | | (interactive) |
| | | (find-file "~/.emacs.d/init.el")) |
| | | (global-set-key (kbd "C-c e i") 'init-visit) |
| | | #+END_SRC |
| | | ** Reload configuration |
| | | #+BEGIN_SRC emacs-lisp |
| | | (defun config-reload () |
| | |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package rainbow-mode |
| | | :ensure t |
| | | :diminish rainbow-mode |
| | | :init |
| | | (add-hook 'prog-mode-hook 'rainbow-mode)) |
| | | #+END_SRC |
| | |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package undo-tree |
| | | :ensure t |
| | | :diminish undo-tree-mode |
| | | :config |
| | | (global-undo-tree-mode)) |
| | | #+END_SRC |
| | |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package volatile-highlights |
| | | :ensure t |
| | | :diminish volatile-highlights-mode |
| | | :config |
| | | (volatile-highlights-mode t)) |
| | | #+END_SRC |
| | |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package workgroups2 |
| | | :ensure t |
| | | :diminish workgroups-mode |
| | | :config |
| | | (workgroups-mode 1)) |
| | | #+END_SRC |
| | |
| | | * Programming tweaks |
| | | ** Yasnippet |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package yasnippet |
| | | :ensure t |
| | | :diminish yas-minor-mode |
| | | :config |
| | | (use-package yasnippet-snippets |
| | | :ensure t) |
| | | (yas-reload-all)) |
| | | (use-package yasnippet |
| | | :ensure t |
| | | :diminish yas-minor-mode |
| | | :config |
| | | (use-package yasnippet-snippets |
| | | :ensure t) |
| | | (yas-reload-all) |
| | | (yas-global-mode 1)) |
| | | #+END_SRC |
| | | ** flycheck |
| | | #+BEGIN_SRC emacs-lisp |
| | |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package company |
| | | :ensure t |
| | | :hook (prog-mode) |
| | | :diminish company-mode |
| | | :config |
| | | (add-hook 'prog-mode-hook 'company-mode) |
| | | (setq company-idle-delay 0) |
| | | (setq company-minimum-prefix-length 3)) |
| | | #+END_SRC |
| | | ** Language specific configs |
| | | *** C/C++ |
| | | **** yasnippet |
| | | #+BEGIN_SRC emacs-lisp |
| | | (add-hook 'c++-mode-hook 'yas-minor-mode) |
| | | (add-hook 'c-mode-hook 'yas-minor-mode) |
| | | #+END_SRC |
| | | **** flycheck clang |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package flycheck-clang-analyzer |
| | | :ensure t |
| | | :config |
| | | (with-eval-after-load 'flycheck |
| | | (require 'flycheck-clang-analyzer) |
| | | (flycheck-clang-analyzer-setup))) |
| | | #+END_SRC |
| | | **** company |
| | | #+BEGIN_SRC emacs-lisp |
| | | (add-hook 'c-mode-common-hook |
| | | (lambda () |
| | | (define-key c-mode-base-map [(tab)] 'company-complete)))) |
| | | |
| | | (use-package company-c-headers |
| | | :ensure t |
| | | :after company |
| | | :config |
| | | (add-hook 'c++-mode-hook 'company-mode) |
| | | (add-hook 'c-mode-hook 'company-mode)) |
| | | |
| | | (use-package company-irony |
| | | :ensure t |
| | | :config |
| | | (add-to-list company-backends '((company-c-headers |
| | | company-dabbrev-code |
| | | company-irony)))) |
| | | |
| | | (use-package irony |
| | | :ensure t |
| | | :config |
| | | (add-hook 'c++-mode-hook 'irony-mode) |
| | | (add-hook 'c-mode-hook 'irony-mode) |
| | | (add-hook 'irony-mode-hook 'irony-cdb-autosetup-compile-options)) |
| | | #+END_SRC |
| | | *** emacs-lisp |
| | | **** eldoc |
| | | #+BEGIN_SRC emacs-lisp |
| | | (add-hook 'emacs-lisp-mode-hook 'eldoc-mode) |
| | | #+END_SRC |
| | | **** yasnippet |
| | | #+BEGIN_SRC emacs-lisp |
| | | (add-hook 'emacs-lisp-mode-hook 'yas-minor-mode) |
| | | #+END_SRC |
| | | **** company |
| | | #+BEGIN_SRC emacs-lisp |
| | | (add-hook 'emacs-lisp-mode-hook 'company-mode) |
| | | |
| | | (use-package slime |
| | | :ensure t |
| | | :config |
| | | (setq inferior-lisp-program "/usr/bin/sbcl") |
| | | (setq slime-contribs '(slime-fancy))) |
| | | |
| | | (use-package slime-company |
| | | :ensure t |
| | | :init |
| | | (require 'company) |
| | | (slime-setup '(slime-fancy slime-company))) |
| | | #+END_SRC |
| | | *** x86 |
| | | **** x86-lookup |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package x86-lookup |
| | | :ensure t |
| | | :init |
| | | (setq x86-lookup-pdf "D:/Coding/x86-instructions.pdf") |
| | | :bind ("C-h x" . x86-lookup)) |
| | | #+END_SRC |
| | | *** Latex |
| | | **** AucTex |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package tex |
| | | :ensure auctex |
| | | :config |
| | | (setq TeX-auto-save t) |
| | | (setq TeX-parse-self t) |
| | | (setq doc-view-ghostscript-program "c:/msys64/mingw64/bin/gswin32c.exe") |
| | | (setq preview-gs-command "c:/msys64/mingw64/bin/gs.exe")) |
| | | #+END_SRC |
| | | **** Company |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package company-math |
| | | :ensure t |
| | | :after company |
| | | :config |
| | | (add-to-list 'company-backends 'company-math-symbols-unicode)) |
| | | #+END_SRC |
| | | **** Preview pane |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package latex-preview-pane |
| | | :ensure t |
| | | :config |
| | | (latex-preview-pane-enable)) |
| | | #+END_SRC |
| | | *** PlantUML |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package plantuml-mode |
| | | :ensure t |
| | | :init |
| | | (setq plantuml-jar-path "c:/ProgramData/chocolatey/lib/plantuml/tools/plantuml.jar")) |
| | | #+END_SRC |
| | | ** Magit |
| | | #+BEGIN_SRC emacs-lisp |
| | |
| | | :map c++-mode-map |
| | | ("M-RET" . 'srefactor-refactor-at-point))) |
| | | #+END_SRC |
| | | ** Language specific configs |
| | | *** C/C++ |
| | | **** yasnippet |
| | | #+BEGIN_SRC emacs-lisp |
| | | (add-hook 'c++-mode-hook 'yas-minor-mode) |
| | | (add-hook 'c-mode-hook 'yas-minor-mode) |
| | | #+END_SRC |
| | | **** flycheck clang |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package flycheck-clang-analyzer |
| | | :ensure t |
| | | :config |
| | | (with-eval-after-load 'flycheck |
| | | (require 'flycheck-clang-analyzer) |
| | | (flycheck-clang-analyzer-setup))) |
| | | #+END_SRC |
| | | **** company |
| | | #+BEGIN_SRC emacs-lisp |
| | | (add-hook 'c-mode-common-hook |
| | | (lambda () |
| | | (define-key c-mode-base-map [(tab)] 'company-complete))) |
| | | |
| | | (use-package company-c-headers |
| | | :ensure t |
| | | :after company |
| | | :config |
| | | (add-hook 'c++-mode-hook 'company-mode) |
| | | (add-hook 'c-mode-hook 'company-mode)) |
| | | |
| | | (use-package company-irony |
| | | :ensure t |
| | | :config |
| | | (add-to-list 'company-backends '(company-c-headers |
| | | company-dabbrev-code |
| | | company-irony))) |
| | | |
| | | (use-package irony |
| | | :ensure t |
| | | :config |
| | | (add-hook 'c++-mode-hook 'irony-mode) |
| | | (add-hook 'c-mode-hook 'irony-mode) |
| | | (add-hook 'irony-mode-hook 'irony-cdb-autosetup-compile-options)) |
| | | #+END_SRC |
| | | *** emacs-lisp |
| | | **** eldoc |
| | | #+BEGIN_SRC emacs-lisp |
| | | (add-hook 'emacs-lisp-mode-hook 'eldoc-mode) |
| | | #+END_SRC |
| | | **** yasnippet |
| | | #+BEGIN_SRC emacs-lisp |
| | | (add-hook 'emacs-lisp-mode-hook 'yas-minor-mode) |
| | | #+END_SRC |
| | | **** company |
| | | #+BEGIN_SRC emacs-lisp |
| | | (add-hook 'emacs-lisp-mode-hook 'company-mode) |
| | | |
| | | (use-package slime |
| | | :ensure t |
| | | :config |
| | | (setq inferior-lisp-program "/usr/bin/sbcl") |
| | | (setq slime-contribs '(slime-fancy))) |
| | | |
| | | (use-package slime-company |
| | | :ensure t |
| | | :init |
| | | (require 'company) |
| | | (slime-setup '(slime-fancy slime-company))) |
| | | #+END_SRC |
| | | *** x86 |
| | | **** x86-lookup |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package x86-lookup |
| | | :ensure t |
| | | :init |
| | | (setq x86-lookup-pdf "D:/Coding/x86-instructions.pdf") |
| | | :bind ("C-h x" . x86-lookup)) |
| | | #+END_SRC |
| | | *** Latex |
| | | **** AucTex |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package tex |
| | | :ensure auctex |
| | | :config |
| | | (setq TeX-auto-save t) |
| | | (setq TeX-parse-self t) |
| | | (setq doc-view-ghostscript-program "c:/msys64/mingw64/bin/gswin32c.exe") |
| | | (setq preview-gs-command "c:/msys64/mingw64/bin/gs.exe")) |
| | | #+END_SRC |
| | | **** Company |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package company-math |
| | | :ensure t |
| | | :after company |
| | | :config |
| | | (add-to-list 'company-backends 'company-math-symbols-unicode)) |
| | | #+END_SRC |
| | | **** Preview pane |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package latex-preview-pane |
| | | :ensure t |
| | | :config |
| | | (latex-preview-pane-enable)) |
| | | #+END_SRC |
| | | *** PlantUML |
| | | #+BEGIN_SRC emacs-lisp |
| | | (use-package plantuml-mode |
| | | :ensure t |
| | | :init |
| | | (setq plantuml-jar-path "c:/ProgramData/chocolatey/lib/plantuml/tools/plantuml.jar")) |
| | | #+END_SRC |
| | | * Org mode |
| | | ** Up to date org |
| | | #+BEGIN_SRC emacs-lisp |
| | |
| | | (setq org-export-with-smart-quotes t) |
| | | (setq org-src-window-setup 'current-window) |
| | | (add-hook 'org-mode-hook 'org-indent-mode) |
| | | (diminish 'org-indent-mode) |
| | | (diminish 'visual-line-mode) |
| | | #+END_SRC |
| | | ** Line wrapping |
| | | #+BEGIN_SRC emacs-lisp |