Ottimizzazione del tempo di bootstrap di Emacs

This commit is contained in:
Fabio Scotto di Santolo
2019-12-13 19:24:02 +01:00
parent 67318219ca
commit 880f599ba6
7 changed files with 27 additions and 13 deletions

9
.emacs
View File

@@ -5,7 +5,6 @@
;specificaly here and not
;anywhere else ~_~
(load "~/.emacs.rc/rc.el")
(load "~/.emacs.rc/misc-rc.el")
(load "~/.emacs.rc/appearance-rc.el")
(load "~/.emacs.rc/ido-smex-rc.el")
@@ -13,7 +12,6 @@
(load "~/.emacs.rc/paredit-rc.el")
(load "~/.emacs.rc/emacs-lisp-rc.el")
(load "~/.emacs.rc/haskell-mode-rc.el")
;;(load "~/.emacs.rc/whitespace-mode-rc.el")
(load "~/.emacs.rc/magit-rc.el")
(load "~/.emacs.rc/multiple-cursors-rc.el")
(load "~/.emacs.rc/openwith-rc.el")
@@ -30,7 +28,6 @@
(load "~/.emacs.rc/org-babel-rc.el")
(load "~/.emacs.rc/org-capture-rc.el")
(load "~/.emacs.rc/autocommit-rc.el")
(load "~/.emacs.rc/powershell-rc.el")
(load "~/.emacs.rc/eldoc-mode-rc.el")
(load "~/.emacs.rc/recentf-mode-rc.el")
(load "~/.emacs.rc/company-rc.el")
@@ -40,15 +37,17 @@
(load "~/.emacs.rc/latex-mode-rc.el")
(load "~/.emacs.rc/agda2-mode-rc.el")
(load "~/.emacs.rc/move-text-rc.el")
(load "~/.emacs.rc/alchemist.el")
(load "~/.emacs.rc/metals-rc.el")
(load "~/.emacs.rc/neotree-rc.el")
(load "~/.emacs.rc/projectile-rc.el")
;;(load "~/.emacs.rc/powershell-rc.el")
;;(load "~/.emacs.rc/whitespace-mode-rc.el")
(add-to-list 'auto-mode-alist '("\\.ebi\\'" . lisp-mode))
;;; Packages that don't require configuration
(rc/require
'elixir-mode
'scala-mode
'd-mode
'yaml-mode

View File

@@ -13,7 +13,7 @@
'(org-refile-use-outline-path (quote file))
'(package-selected-packages
(quote
(projectile wombat-theme darcula-theme darcula-theme-theme zeal-at-point yaml-mode xquery-mode uuidgen tuareg tt-mode toml-mode tide smex slime rtags rainbow-mode racket-mode racer qml-mode purescript-mode powershell picolisp-mode php-mode paredit pacmacs package-lint org-pomodoro org-cliplink openwith nsis-mode nodejs-repl nix-mode nim-mode nginx-mode neotree nasm-mode multiple-cursors morganey-mode markdown-mode magit love-minor-mode less-css-mode kotlin-mode js2-mode jira-markup-mode jinja2-mode jade-mode jabber ido-ubiquitous htmlize helm-ls-git helm-git-grep helm-cmd-t haskell-mode handlebars-mode gruber-darker-theme groovy-mode graphviz-dot-mode gradle-mode google-translate go-mode glsl-mode ggtags fsharp-mode flycheck-rust fixmee evil erlang ensime emojify elpy elm-mode elfeed editorconfig dropdown-list dockerfile-mode d-mode csv-nav csharp-mode crux cmake-mode clojure-mode cil-mode buffer-move bnfc batch-mode ag ack)))
(alchemist company-c-headers company-cabal company-ctags company-ghc company-ghci company-go company-shell company-web company-erlang wombat-theme darcula-theme darcula-theme-theme zeal-at-point yaml-mode xquery-mode uuidgen tuareg tt-mode toml-mode tide smex slime rtags rainbow-mode racket-mode racer qml-mode purescript-mode powershell picolisp-mode php-mode paredit pacmacs package-lint org-pomodoro org-cliplink openwith nsis-mode nodejs-repl nix-mode nim-mode nginx-mode neotree nasm-mode multiple-cursors morganey-mode markdown-mode magit love-minor-mode less-css-mode kotlin-mode js2-mode jira-markup-mode jinja2-mode jade-mode jabber ido-ubiquitous htmlize helm-ls-git helm-git-grep helm-cmd-t haskell-mode handlebars-mode gruber-darker-theme groovy-mode graphviz-dot-mode gradle-mode google-translate go-mode glsl-mode ggtags fsharp-mode flycheck-rust fixmee evil erlang ensime emojify elpy elm-mode elfeed editorconfig dropdown-list dockerfile-mode d-mode csv-nav csharp-mode crux cmake-mode clojure-mode cil-mode buffer-move bnfc batch-mode ag ack)))
'(safe-local-variable-values
(quote
((haskell-process-args-cabal-new-repl "--ghc-option=-ferror-spans" "--ghc-option=-Wno-missing-home-modules" "exe:HyperNerd")

8
.emacs.rc/alchemist.el Normal file
View File

@@ -0,0 +1,8 @@
(setq alchemist-mix-command "/usr/bin/mix")
(setq alchemist-iex-program-name "/usr/bin/iex") ;; default: iex
(setq alchemist-execute-command "/usr/bin/elixir") ;; default: elixir
(setq alchemist-compile-command "/usr/bin/elixirc") ;; default: elixirc
(setq alchemist-test-display-compilation-output t)
(setq alchemist-hooks-compile-on-save t)

View File

@@ -1,5 +1,3 @@
(package-initialize)
(require 'package)
;; Install use-package if not already installed
@@ -30,6 +28,7 @@
;; Enable nice rendering of diagnostincs like compile errors.
(use-package flycheck
:init (global-flycheck-mode))
(setq-default flycheck-disabled-checkers '(emacs-lisp-checkdoc))
(use-package lsp-mode
;; Optional - enable lsp-mode automatically in scala files

View File

@@ -8,13 +8,13 @@
tab-width 4
indent-tabs-mode nil
compilation-scroll-output t
default-input-method "russian-computer"
;; default-input-method "russian-computer"
visible-bell (equal system-type 'windows-nt))
(defun rc/colorize-compilation-buffer ()
(toggle-read-only)
(read-only-mode)
(ansi-color-apply-on-region compilation-filter-start (point))
(toggle-read-only))
(read-only-mode))
(add-hook 'compilation-filter-hook 'rc/colorize-compilation-buffer)
(defun rc/buffer-file-name ()
@@ -133,4 +133,13 @@ This command does the inverse of `fill-paragraph'."
(setq confirm-kill-emacs 'y-or-n-p)
(add-hook 'emacs-startup-hook
(lambda ()
(message "Emacs ready in %s with %d garbage collections."
(format "%.2f seconds"
(float-time (time-subtract after-init-time before-init-time)))
gcs-done)))
(server-start)

View File

@@ -1,5 +1,3 @@
(package-initialize)
(require 'neotree)
(global-set-key [f8] 'neotree-toggle)

View File

@@ -3,6 +3,7 @@
email = fabio.scottodisantolo@gmail.com
[core]
pager =
editor = emacs -nw
[push]
followTags = true
[remote "origin"]