After copying this config you need to install use-package
via M-x package-install
Some initial necessary shit
(menu-bar-mode -1) ; Le classique
(tool-bar-mode -1) ; Le classique
(scroll-bar-mode -1) ; Le classique
(global-display-line-numbers-mode 1) ; Display numbers on lines
(windmove-default-keybindings) ; thing for moving around windows
(setq-default cursor-type 'bar) ; No comments ;)
(global-hl-line-mode t) ; highlight for current line
(set-face-attribute 'default nil :family "JetBrainsMono Nerd Font")
(set-face-attribute 'default nil :height 120)
(require 'package)
(add-to-list 'package-archives
'("melpa" . "https://melpa.org/packages/")
'("melpa-stable" . "http://stable.melpa.org/packages/"))
;; Rust
(use-package rust-mode
:config
(setq rust-format-on-save t)
(define-key rust-mode-map (kbd "C-c C-c") 'rust-run))
;; Python
(use-package python-mode
:ensure t)
;; Web development
(use-package web-mode
:ensure t)
(use-package emmet-mode
:ensure t)
(use-package js2-mode
:ensure t)
(use-package php-mode
:ensure t)
(use-package lsp-mode
:init (setq lsp-keymap-prefix "C-c l")
:hook ((rust-mode . lsp)
(python-mode . lsp)
(web-mode . lsp)
(php-mode . lsp)
(swift-mode . lsp)
;; if you want which-key integration
(lsp-mode . lsp-enable-which-key-integration))
:config (lsp-treemacs-sync-mode 1)
:commands lsp)
(use-package lsp-ui
:commands lsp-ui-mode)
(use-package helm-lsp
:commands helm-lsp-workspace-symbol)
(use-package lsp-treemacs
:commands lsp-treemacs-errors-list)
Documentation for ef-themes
: https://protesilaos.com/emacs/ef-themes#h:ac76ded0-af9b-4566-aff9-75142ef2d4ef
;; ef-themes (from modus author)
;; (use-package ef-themes ;;
;; :config ;;
;; (setq ef-themes-mixed-fonts t ;;
;; ef-themes-variable-pitch-ui t ;;
;; ef-themes-headings ;;
;; '((0 . (variable-pitch light 1.9)) ;;
;; (1 . (variable-pitch light 1.8)) ;;
;; (2 . (variable-pitch regular 1.7)) ;;
;; (3 . (variable-pitch regular 1.6)) ;;
;; (4 . (variable-pitch regular 1.5)) ;;
;; (5 . (variable-pitch 1.4)) ; absence of weight means `bold' ;;
;; (6 . (variable-pitch 1.3)) ;;
;; (7 . (variable-pitch 1.2)) ;;
;; (t . (variable-pitch 1.1))))) ;;
;; ;;
;; ;; Doom themes ;;
(use-package doom-themes
:config
(setq doom-themes-enable-bold t
doom-themes-enable-italic t)
(load-theme 'doom-dracula t)
(doom-themes-visual-bell-config)
(setq doom-themes-treemacs-theme "doom-atom")
(doom-themes-treemacs-config)
(doom-themes-org-config))
;; (defun my/apply-theme (appearance)
;; "Load theme, taking current system APPEARANCE into consideration."
;; (mapc #'disable-theme custom-enabled-themes)
;; (pcase appearance
;; ('light (load-theme 'ef-summer t))
;; ('dark (load-theme 'ef-winter t))))
;; (add-hook 'ns-system-appearance-change-functions #'my/apply-
;; theme)
;; Doom modeline
(use-package doom-modeline
:init (doom-modeline-mode)
:custom
;; (doom-modeline-major-mode-icon t)
(doom-modeline-major-mode-color-icon nil)
(doom-modeline-icon (display-graphic-p))
(doom-modeline-buffer-modification-icon t)
(doom-modeline-flycheck-icon t)
(doom-modeline-checker-simple-format t)
(doom-modeline-buffer-encoding t)
(doom-modeline-height 30))
(use-package all-the-icons
:ensure t)
(use-package nyan-mode
:init (nyan-mode))
(use-package fancy-battery
:init (fancy-battery-mode)
:config (setq fancy-battery-show-percentage t))
;; Treemacs
(use-package treemacs
:ensure t)
;; Autocomplete for emacs
(use-package helm
:init (helm-mode t)
:config
(global-set-key (kbd "M-x") 'helm-M-x))
;; Better dired
(use-package dirvish
:init (dirvish-override-dired-mode))
(use-package company
:config (add-hook 'after-init-hook 'global-company-mode))
(use-package company-box
:hook (company-mode . company-box-mode))
(use-package which-key
:config
(which-key-mode))
(use-package vterm
:commands vterm
:config
(setq term-prompt-regexp "^[^#$%>\n]*[#$%>] *") ;; Set this to match your custom shell prompt
(setq vterm-max-scrollback 10000))
Some list:
- [ ] Some entry
- [X] jskfjdk
'(org-hide-emphasis-markers t)
(font-lock-add-keywords
'org-mode
'(("^ *\\([-]\\) "
(0 (prog1 () (compose-region (match-beginning 1) (match-end 1) "•"))))))
(use-package org-bullets
:after org
:hook
(org-mode . (lambda () (org-bullets-mode 1))))
'(org-mode . '(lambda ()
"Beautify Org Checkbox Symbol"
(push '("[ ]" . "☐" ) prettify-symbols-alist)
(push '("[X]" . "☑" ) prettify-symbols-alist)
(push '("[-]" . "⊡" ) prettify-symbols-alist)
(prettify-symbols-mode)))
'(prettify-symbols-unprettify-at-point 'right-edge)
(defface org-checkbox-done-text
'((t (:foreground "#71696A" :strike-through t)))
"Face for the text part of a checked org-mode checkbox.")
;; (font-lock-add-keywords
;; 'org-mode
;; `(("^[ \t]*\\(?:[-+*]\\|[0-9]+[).]\\)[ \t]+\\(\\(?:\\[@\\(?:start:\\)?[0-9]+\\][ \t]*\\)?\\[\\(?:X\\|\\([0-9]+\\)/\\2\\)\\][^\n]*\n\\)"
;; 1 'org-checkbox-done-text prepend))
;; 'append)
(use-package markdown-mode
:ensure t)
;; :config (setq markdown-css-paths '("~/.emacs.d/custom-md-css/default.css")))
;; For converting markdown and org files to pdf
(use-package pandoc-mode
:ensure t)
;; Idk why it's here, but why not lol
(use-package pdf-tools
:ensure t)
;; Preview for org files
(use-package org-preview-html
:ensure t)
;; Preview for markdown
(use-package grip-mode
:config (setq grip-preview-use-webkit t))