diff options
author | Hunt <lizhunt@amazon.com> | 2025-06-12 09:30:33 -0700 |
---|---|---|
committer | Hunt <lizhunt@amazon.com> | 2025-06-12 09:30:45 -0700 |
commit | 072aa746c02e8a423c128cfc253ac2c410eb47e1 (patch) | |
tree | 5677ff905c9a563ac8c36a26f0d96503ae56a472 /dots/emacs/.config/emacs.d | |
parent | 058b3be4feb7eda3810172537039c48ac36441a5 (diff) | |
download | dotfiles-072aa746c02e8a423c128cfc253ac2c410eb47e1.tar.gz dotfiles-072aa746c02e8a423c128cfc253ac2c410eb47e1.zip |
Fixes some emacs stuff
Diffstat (limited to 'dots/emacs/.config/emacs.d')
-rw-r--r-- | dots/emacs/.config/emacs.d/early-init.el | 5 | ||||
-rw-r--r-- | dots/emacs/.config/emacs.d/empressomacs.org.j2 | 264 | ||||
-rw-r--r-- | dots/emacs/.config/emacs.d/init.el | 51 |
3 files changed, 0 insertions, 320 deletions
diff --git a/dots/emacs/.config/emacs.d/early-init.el b/dots/emacs/.config/emacs.d/early-init.el deleted file mode 100644 index 7bb24d4..0000000 --- a/dots/emacs/.config/emacs.d/early-init.el +++ /dev/null @@ -1,5 +0,0 @@ -;;-- <early-init> -- -(add-to-list 'default-frame-alist '(undecorated-round . t)) -(setq package-enable-at-startup t) -;;-- </early-init> -- - diff --git a/dots/emacs/.config/emacs.d/empressomacs.org.j2 b/dots/emacs/.config/emacs.d/empressomacs.org.j2 deleted file mode 100644 index 8aa8be5..0000000 --- a/dots/emacs/.config/emacs.d/empressomacs.org.j2 +++ /dev/null @@ -1,264 +0,0 @@ -#+TITLE: emprespresso's settings -#+AUTHOR: emprespresso -#+STARTUP: fold - -* melpa -#+BEGIN_SRC emacs-lisp - (require 'package) - (add-to-list 'package-archives - '("melpa" . "https://melpa.org/packages/") t) -#+END_SRC -* macos hacks that have to be run before most stuff. -** image types. -#+BEGIN_SRC emacs-lisp - (setq image-types '(svg png gif tiff jpeg xpm xbm pbg)) -#+END_SRC -* yeah, be evil. whatcha gonna do about it?? huh?? >:P -#+BEGIN_SRC emacs-lisp - (use-package evil - :init - (setq evil-want-integration t) - (setq evil-want-keybinding nil) - (setq evil-want-C-u-scroll t) - (setq evil-want-C-i-jump nil) - (setq evil-shift-width {{ editorconfig.tab_width }}) - (setq evil-cross-lines t) - (setq evil-respect-visual-line-mode t) - (setq evil-vsplit-window-below t) - (setq evil-split-window-below t) - (setq evil-undo-system 'undo-redo) - :config - (evil-mode 1) - (define-key evil-insert-state-map (kbd "C-g") 'evil-normal-state) - - (evil-global-set-key 'motion "j" 'evil-next-visual-line) - (evil-global-set-key 'motion "k" 'evil-previous-visual-line) - - (add-hook 'evil-visual-activate-hook - #'(lambda () - (global-hl-line-mode 0))) - - (add-hook 'evil-visual-deactivate-hook - #'(lambda () - (global-hl-line-mode 1))) - - (setq evil-want-fine-undo t) - (evil-set-initial-state 'messages-buffer-mode 'normal)) -#+END_SRC - -* misc. emacs stuff -** files and autosaves -#+BEGIN_SRC emacs-lisp - (setq auto-save-default nil - make-backup-files nil - create-lockfiles nil) - (global-auto-revert-mode t) ;; Change files on disk as they are updated -#+END_SRC -** env.PATH -#+BEGIN_SRC emacs-lisp - (use-package exec-path-from-shell - :ensure t - :init - (when (memq window-system '(mac ns x)) - (exec-path-from-shell-initialize))) -#+END_SRC -** case-region -#+BEGIN_SRC emacs-lisp - (put 'downcase-region 'disabled nil) - (put 'upcase-region 'disabled nil) -#+END_SRC -** silence, bell -#+BEGIN_SRC emacs-lisp - (setq ring-bell-function 'ignore) -#+END_SRC -* appearance -** global -#+BEGIN_SRC emacs-lisp - ;; > expert users often turn off the menu bar - ;; > https://www.gnu.org/software/emacs/manual/html_node/emacs/Menu-Bars.html - ;; we're experts, right?? (*^.^*) - (menu-bar-mode -1) - - ;; don't show startup screen, go straight to scratch - (setq inhibit-startup-screen t) -#+END_SRC -** gui -*** clutter -#+BEGIN_SRC emacs-lisp - ;; don't show clutter - (tool-bar-mode -1) - - ;; make line-wrap arrows basically invisible by setting the fringe area - ;; dimensions to 1 - (set-fringe-mode '(1 . 1)) - - ;; disable scroll bars - (scroll-bar-mode nil) - (horizontal-scroll-bar-mode nil) -#+END_SRC -*** line - related -#+BEGIN_SRC emacs-lisp - ;; move by whole line units, not visually - (setq line-move-visual nil) - - ;; make comfy - (setq line-spacing 0.24) - - ;; highlight current line - (global-hl-line-mode) - - ;; fixes an "issue", where the frame doesn't use the entire space available given - ;; by the window manager since the frame will resize only by factors of the line - ;; height by default. - ;; especially noticeable when tiling ヽ(ー_ー )ノ - (setq frame-resize-pixelwise t) -#+END_SRC -*** icons -must run ~(all-the-icons-install-fonts)~ and ~(nerd-fonts-install-fonts)~ -#+BEGIN_SRC emacs-lisp - (use-package all-the-icons - :ensure t) - (use-package nerd-icons - :ensure t) -#+END_SRC -*** modeline -#+BEGIN_SRC emacs-lisp - (use-package doom-modeline - :ensure t - :config - (doom-modeline-mode 1)) -#+END_SRC -*** themes -#+BEGIN_SRC emacs-lisp - (use-package doom-themes - :ensure t - :config - (setq doom-themes-enable-bold t ; enable bold globally - doom-themes-enable-italic t) ; enable italics globally - - ;; flash mode-line on errors - (doom-themes-visual-bell-config) - - (doom-themes-neotree-config) - - ;; corrects (and improves) org-mode's native fontification. - (doom-themes-org-config)) -#+END_SRC -*** eager loading of theme -#+BEGIN_SRC emacs-lisp - (require 'filenotify) - - (setq *theme-file* "~/.config/theme/emacs.el") - (file-notify-add-watch *theme-file* '(change) - #'(lambda (event) (load-file *theme-file*))) -#+END_SRC - -* neotree -#+BEGIN_SRC emacs-lisp - (use-package neotree - :ensure t - :bind ("C-c j" . 'neotree-toggle) - :init - ;; slow rendering - (setq inhibit-compacting-font-caches t) - - ;; set icons theme - (setq neo-theme (if (display-graphic-p) 'icons 'arrow)) - (setq neo-window-width 35) - - ;; every time when the neotree window is opened, let it find current file - ;; and jump to node - (setq neo-smart-open t) - - ;; when running ‘projectile-switch-project’ (C-c p p), ‘neotree’ - ;; will change root automatically - (setq projectile-switch-project-action 'neotree-projectile-action) - - ;; show hidden files - (setq-default neo-show-hidden-files t)) -#+END_SRC -* org mode -** misc vars -#+BEGIN_SRC emacs-lisp - (setq org-startup-indented t - org-html-postamble nil - org-html-preamble t - org-src-tab-acts-natively t) -#+END_SRC -** roam -#+BEGIN_SRC emacs-lisp - (use-package org-roam - :straight t) -#+END_SRC -** babel -#+BEGIN_SRC emacs-lisp - (org-babel-do-load-languages - 'org-babel-load-languages - '((lisp . t) - (emacs-lisp . t) - (python . t))) -#+END_SRC -** org-bullets -#+BEGIN_SRC emacs-lisp - (use-package org-bullets - :ensure t - :init - (add-hook 'org-mode-hook (lambda () (org-bullets-mode 1)))) -#+END_SRC -** org-appear -#+BEGIN_SRC emacs-lisp - (use-package org-appear - :ensure t - :init - (add-hook 'org-mode-hook 'org-appear-mode)) -#+END_SRC -** presentations -#+BEGIN_SRC emacs-lisp - (use-package org-present - :ensure t - :straight '(org-present - :type git - :host github - :repo "rlister/org-present")) -#+END_SRC -* major modes -** markdown -#+BEGIN_SRC emacs-lisp -(use-package markdown-mode - :ensure t - :mode ("README\\.md\\'" . gfm-mode) - :init (setq markdown-command "multimarkdown") - :bind (:map markdown-mode-map - ("C-c C-e" . markdown-do))) -#+END_SRC -* dev stuff -** completion -#+BEGIN_SRC emacs-lisp - ;; > yasnippet is a template system for emacs. - ;; > it allows you to type an abbreviation and automatically expand it into - ;; function templates. - ;; https://github.com/joaotavora/yasnippet/blob/master/README.mdown - (use-package yasnippet - :ensure t - :init (yas-global-mode 1)) -#+END_SRC -** lsp -#+BEGIN_SRC emacs-lisp - ;; pip3 install epc orjson sexpdata six setuptools \ - ;; paramiko rapidfuzz watchdog packaging - (use-package lsp-bridge - :straight - '(lsp-bridge :type git :host github - :repo "manateelazycat/lsp-bridge" - :files (:defaults - "*.el" "*.py" "acm" "core" "langserver" - "multiserver" "resources") - :build (:not compile)) - :init (global-lsp-bridge-mode)) -#+END_SRC -** format -#+BEGIN_SRC emacs-lisp - (use-package format-all - :ensure t - :bind (("C-c C-f" . format-all-region))) -#+END_SRC diff --git a/dots/emacs/.config/emacs.d/init.el b/dots/emacs/.config/emacs.d/init.el deleted file mode 100644 index bff8177..0000000 --- a/dots/emacs/.config/emacs.d/init.el +++ /dev/null @@ -1,51 +0,0 @@ -;;-- <helpers> -- -(defun find-user-file (file-name) - (expand-file-name file-name user-emacs-directory)) - -(defmacro in-remote-buffer (url &rest body) - "evals in a buffer whose contents are raw retrieved from (url)" - `(with-current-buffer (url-retrieve-synchronously - ,url 'silent 'inhibit-cookies) - ,body)) - -(defun eval-remote (url) - "essentially `curl (url) | sh` (ノ´ヮ`)ノ*" - (in-remote-buffer url - (eval-buffer))) -;;-- </helpers> -- - -;;-- <straight.el> -- -;;(( what abt gay.el („• ֊ •„) hehe )) - -;; bootstrap, installing if it doesn't yet exist. -(defvar *straight-version* 5) -(defvar *straight-bootstrap-file* - (find-user-file "straight/repos/straight.el/bootstrap.el")) -(defvar *straight-src* - "https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el") -(defun bootstrap-straight (&optional version file src) - "bootstrap straight (version), eval'ing (file) or falling back to (src)" - (or version (setq version *straight-version*)) - (or file (setq file *straight-bootstrap-file*)) - (or src (setq src *stragith-src*)) - - (if file-exists-p file) - (load file nil 'nomessage) - (eval-remote src)) -(bootstrap-staight) - -;; install it and use it by default! -(straight-use-package 'use-package) -(use-package straight - :custom - (straight-use-package-by-default t)) -;;-- </straight.el> -- - -;;-- <org_init> -- -(use-package org - :straight (:type built-in)) - -(defvar *settings-org* "empressomacs.org") -(org-babel-load-file (find-user-file *settings-org*)) -;;-- </org_init> -- - |