#+TITLE Emacs config
Make startup faster by reducing the frequency of garbage collection and then use a hook to measure Emacs startup time.
;; The default is 800 kilobytes. Measured in bytes.
(setq gc-cons-threshold (* 50 1000 1000))
;; Profile emacs startup
(add-hook 'emacs-startup-hook
(lambda ()
(message "*** Emacs loaded in %s with %d garbage collections."
(format "%.2f seconds"
(float-time
(time-subtract after-init-time before-init-time)))
gcs-done)))
(set-frame-parameter (selected-frame) 'alpha '(95 . 85))
(add-to-list 'default-frame-alist '(alpha . (95 . 85)))
(scroll-bar-mode -1)
(menu-bar-mode -1)
(tool-bar-mode -1)
(tooltip-mode -1)
(global-display-line-numbers-mode t)
;; Disable line numbers for some modes
(dolist (mode '(org-mode-hook
term-mode-hook
shell-mode-hook
eshell-mode-hook))
(add-hook mode (lambda () (display-line-numbers-mode 0))))
;; Should help with Emacs slowing down on big one-liners
(setq bidi-paragraph-direction 'left-to-right)
(require 'package)
(setq package-enable-at-startup nil)
(setq package-archives
'(("melpa" . "https://melpa.org/packages/")
("gnu" . "https://elpa.gnu.org/packages/")
("org" . "http://orgmode.org/elpa/")))
(package-initialize)
(unless (package-installed-p 'use-package)
(package-refresh-contents)
(package-install 'use-package))
(eval-when-compile
(require 'use-package))
(use-package diminish :ensure t)
(use-package use-package-ensure-system-package :ensure t)
This is too slow
;; (use-package exec-path-from-shell
;; :ensure t
;; :config (exec-path-from-shell-initialize))
;; Enable copy/past-ing from clipboard
(setq select-enable-clipboard t)
;; Always reload the file if it changed on disk, see also: auto-revert-tail-mode
(global-auto-revert-mode 1)
;; Auto update dired when files change
(add-hook 'dired-mode-hook 'auto-revert-mode)
(use-package which-key
:ensure t
:init (which-key-mode)
:diminish which-key-mode
:config
(setq which-key-idle-delay 0.3))
Auto-linting fix https://github.com/aaronjensen/eslintd-fix https://github.com/jscheid/prettier.el https://github.com/prettier/prettier-emacs
There’s built-in export to icalendar. Set that up for Thunderbird icalendar. Here’s an org icalendar import. https://github.com/vjohansen/emacs-config/blob/master/org-import-calendar.el
With those two we should now have end-to-end Thunderbird (or whatever icalendar), Org Agenda and Orgzly integration.
https://github.com/hlissner/emacs-doom-themes https://monokai.pro/vscode https://www.nordtheme.com/docs https://github.com/atomiks/moonlight-vscode-theme https://citylights.xyz/