diff --git a/.emacs.d/custom.el b/.emacs.d/custom.el new file mode 100644 index 0000000..3dfb2cc --- /dev/null +++ b/.emacs.d/custom.el @@ -0,0 +1,38 @@ +(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. + '(package-selected-packages + (quote + (nlinum solarized-theme helm-flycheck helm-flyspell yaml-mode web-mode sr-speedbar sokoban smart-compile pythonic python-mode powerline poker php-mode openwith markdown-mode magit json-mode js-comint jedi javadoc-lookup java-snippets java-imports hydandata-light-theme helm-spotify helm-package helm-ls-git helm-bibtex flycheck-pos-tip flycheck-color-mode-line fish-mode diffview cython-mode company-web company-math company-jedi company-dict company-c-headers company-auctex ac-octave ac-math ac-c-headers 2048-game))) + '(safe-local-variable-values + (quote + ((company-clang-arguments + ("-std=c++14" "-I/home/mcapelle/Dev/cpp/include/" "-I/home/mcapelle/Dev/cpp/lns/lib/build/include/")) + (company-clang-arguments . clang-args) + (eval setq clang-args + ("-std=c++14" "-I/home/mcapelle/Dev/cpp/include/" "-I/home/mcapelle/Dev/cpp/lns/lib/build/include/")) + (encoding . utf-8) + (company-clang-arguments "-std=c++14" "-I/home/mcapelle/Dev/cpp/include/" "-I/home/mcapelle/Dev/cpp/lns/lib/build/include/"))))) +;; (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. +;; '(powerline-active1 ((t (:inherit nil :background "grey11" :foreground "white")))) +;; '(powerline-active2 ((t (:inherit nil :background "grey40" :foreground "white")))) +;; '(powerline-inactive1 ((t (:inherit nil :background "gray11" :foreground "white")))) +;; '(powerline-inactive2 ((t (:inherit nil :background "grey20" :foreground "white"))))) +(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. + '(flycheck-color-mode-line-warning-face ((t (:inherit flycheck-fringe-error :background "coral")))) + '(flycheck-error-list-error ((t (:inherit font-lock-warning-face :background "white" :foreground "firebrick" :slant normal :weight bold :height 1.0 :width normal)))) + '(flycheck-error-list-warning ((t (:inherit warning)))) + '(flycheck-fringe-error ((t (:inherit font-lock-warning-face :background "firebrick" :foreground "white")))) + '(flycheck-fringe-warning ((t (:inherit warning)))) + '(linum ((t (:inherit fringe :background "white" :foreground "gray")))) + '(whitespace-space ((t (:background "white" :foreground "gray"))))) diff --git a/.emacs.d/init.el b/.emacs.d/init.el index 155ca77..3287f0d 100644 --- a/.emacs.d/init.el +++ b/.emacs.d/init.el @@ -8,8 +8,6 @@ (require 'package) ;; You might already have this line (add-to-list 'package-archives '("melpa" . "http://melpa.org/packages/")) -(add-to-list 'package-archives - '("melpa" . "http://melpa.milkbox.net/packages/")) (when (< emacs-major-version 24) ;; For important compatibility libraries like cl-lib (add-to-list 'package-archives '("gnu" . "http://elpa.gnu.org/packages/"))) @@ -91,10 +89,12 @@ :config (yas-global-mode 1)) -(defun flycheck-autolist-hook () - (if (flycheck-has-current-errors-p) - (flycheck-list-errors) - (if (get-buffer "*Flycheck errors*") (delete-window (get-buffer-window "*Flycheck errors*"))))) +;; (defun flycheck-autolist-hook () +;; (let ((buffer-name "*Flycheck errors*")) +;; (if (get-buffer buffer-name) +;; (if (flycheck-has-current-errors-p) +;; (flycheck-list-errors) +;; (delete-window (get-buffer-window buffer-name)))))) (use-package flycheck :config @@ -102,7 +102,8 @@ (add-hook 'flycheck-mode-hook 'flycheck-color-mode-line-mode) (add-hook 'flycheck-mode-hook 'flycheck-pos-tip-mode) (add-hook 'flycheck-after-syntax-check-hook 'flycheck-autolist-hook) - (global-flycheck-mode)) + (global-flycheck-mode) + (setq flycheck-clang-args '("-std=c++14"))) (use-package company :init @@ -111,9 +112,13 @@ company-jedi company-web-html))) (add-hook 'LaTeX-mode-hook 'company-auctex-init) + (add-hook 'python-mode-hook + (lambda () + (setq company-backends '(company-jedi)))) :config (add-hook 'after-init-hook 'global-company-mode) - (global-set-key (kbd "M-/") 'company-complete)) + (global-set-key (kbd "M-/") 'company-complete) + (setq company-clang-arguments '("-std=c++14"))) ;; Latex (use-package tex-mik @@ -271,7 +276,8 @@ ;; python (use-package python-mode - :mode "\\.py\\'") + :mode "\\.py\\'" + :config) ;; (use-package jedi ;; :config @@ -285,23 +291,5 @@ (setq python-indent-offset 4) :mode "\\.pyx\\'") -(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. - '(safe-local-variable-values - (quote - ((company-clang-arguments - ("-std=c++14" "-I/home/mcapelle/Dev/cpp/include/" "-I/home/mcapelle/Dev/cpp/lns/lib/build/include/")) - (company-clang-arguments . clang-args) - (eval setq clang-args - ("-std=c++14" "-I/home/mcapelle/Dev/cpp/include/" "-I/home/mcapelle/Dev/cpp/lns/lib/build/include/")) - (encoding . utf-8) - (company-clang-arguments "-std=c++14" "-I/home/mcapelle/Dev/cpp/include/" "-I/home/mcapelle/Dev/cpp/lns/lib/build/include/"))))) -(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. - ) +(setq custom-file "~/.emacs.d/custom.el") +(load custom-file) diff --git a/install-packages.el b/install-packages.el index 1543103..647cfc0 100644 --- a/install-packages.el +++ b/install-packages.el @@ -8,66 +8,82 @@ (add-to-list 'package-archives '("gnu" . "http://elpa.gnu.org/packages/"))) (package-initialize) ;; You might already have this line + (package-install '2048-game) (package-install 'ac-c-headers) (package-install 'ac-math) (package-install 'ac-octave) -(package-install 'async) -(package-install 'auctex) -(package-install 'auto-complete) -(package-install 'company) (package-install 'company-auctex) (package-install 'company-c-headers) (package-install 'company-dict) (package-install 'company-jedi) (package-install 'company-math) (package-install 'company-web) -(package-install 'concurrent) -(package-install 'ctable) (package-install 'cython-mode) -(package-install 'dash) -(package-install 'dash-functional) -(package-install 'deferred) (package-install 'diffview) -(package-install 'epc) -(package-install 'f) (package-install 'fish-mode) -(package-install 'helm) +(package-install 'flycheck-color-mode-line) +(package-install 'flycheck-pos-tip) (package-install 'helm-bibtex) -(package-install 'helm-core) +(package-install 'helm-flycheck) +(package-install 'helm-flyspell) (package-install 'helm-ls-git) (package-install 'helm-package) (package-install 'helm-spotify) -(package-install 'hydandata-light) +(package-install 'hydandata-light-theme) (package-install 'java-imports) (package-install 'java-snippets) (package-install 'javadoc-lookup) -(package-install 'jdee) (package-install 'jedi) -(package-install 'jedi-core) (package-install 'js-comint) (package-install 'json-mode) +(package-install 'magit) +(package-install 'markdown-mode) +(package-install 'nlinum) +(package-install 'openwith) +(package-install 'php-mode) +(package-install 'poker) +(package-install 'powerline) +(package-install 'python-mode) +(package-install 'pythonic) +(package-install 'smart-compile) +(package-install 'sokoban) +(package-install 'solarized-theme) +(package-install 'sr-speedbar) +(package-install 'web-mode) +(package-install 'yaml-mode) +(package-install 'async) +(package-install 'auctex) +(package-install 'auto-complete) +(package-install 'company) +(package-install 'concurrent) +(package-install 'ctable) +(package-install 'dash) +(package-install 'dash-functional) +(package-install 'deferred) +(package-install 'epc) +(package-install 'epl) +(package-install 'f) +(package-install 'flycheck) +(package-install 'git-commit) +(package-install 'helm) +(package-install 'helm-core) +(package-install 'jedi-core) (package-install 'json-reformat) (package-install 'json-snatcher) -(package-install 'markdown-mode) +(package-install 'let-alist) +(package-install 'magit-popup) (package-install 'math-symbol-lists) (package-install 'multi) (package-install 'nvm) -(package-install 'openwith) (package-install 'parsebib) (package-install 'pcache) -(package-install 'php-mode) -(package-install 'poker) +(package-install 'pkg-info) (package-install 'popup) (package-install 'pos-tip) (package-install 'python-environment) -(package-install 'python-mode) -(package-install 'pythonic) (package-install 's) -(package-install 'smart-compile) -(package-install 'sokoban) -(package-install 'sr-speedbar) -(package-install 'web-completion-) -(package-install 'web-mode) -(package-install 'yaml-mode) +(package-install 'seq) +(package-install 'web-completion-data) +(package-install 'with-editor) (package-install 'yasnippet)