Make babel load path dynamic instead of fixed to .config
Remove crafted-emacs input and tokyonight theme (and uses) Remove old emacs files so I don't get confused
This commit is contained in:
parent
cecc9b63d1
commit
0f35e21716
36
flake.lock
36
flake.lock
|
@ -130,22 +130,6 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"crafted-emacs": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1697837545,
|
||||
"narHash": "sha256-Sucimd2VjeUZ3GZ7kC1W+ix9t30npaHuZgjdvhHuTCU=",
|
||||
"owner": "SystemCrafters",
|
||||
"repo": "crafted-emacs",
|
||||
"rev": "bc6618a2950e354cc6b1bc24c63f3b2c6d71141b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "SystemCrafters",
|
||||
"repo": "crafted-emacs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
|
@ -257,12 +241,10 @@
|
|||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"crafted-emacs": "crafted-emacs",
|
||||
"home-manager": "home-manager",
|
||||
"nix-index-database": "nix-index-database",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"stylix": "stylix",
|
||||
"tokyonight-folke": "tokyonight-folke"
|
||||
"stylix": "stylix"
|
||||
}
|
||||
},
|
||||
"stylix": {
|
||||
|
@ -294,22 +276,6 @@
|
|||
"repo": "stylix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"tokyonight-folke": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1697438389,
|
||||
"narHash": "sha256-ZhWUURBWzRaHr1RpWq4tqcjXuVQIYovUAN5XagVIgtc=",
|
||||
"owner": "folke",
|
||||
"repo": "tokyonight.nvim",
|
||||
"rev": "1e5492bb99d461a5a0d020a119fc76d75945af84",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "folke",
|
||||
"repo": "tokyonight.nvim",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
|
|
14
flake.nix
14
flake.nix
|
@ -15,16 +15,6 @@
|
|||
url = "github:danth/stylix";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
# Non-flake inputs
|
||||
crafted-emacs = {
|
||||
url = "github:SystemCrafters/crafted-emacs";
|
||||
flake = false;
|
||||
};
|
||||
tokyonight-folke = {
|
||||
url = "github:folke/tokyonight.nvim";
|
||||
flake = false;
|
||||
};
|
||||
};
|
||||
|
||||
outputs =
|
||||
|
@ -57,9 +47,7 @@
|
|||
}:
|
||||
let
|
||||
specialArgs = { inherit hostName user; };
|
||||
extraSpecialArgs = specialArgs // {
|
||||
inherit (inputs) crafted-emacs tokyonight-folke;
|
||||
};
|
||||
extraSpecialArgs = specialArgs;
|
||||
in nixpkgs.lib.nixosSystem {
|
||||
inherit system specialArgs;
|
||||
modules = [
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
{ config, lib, pkgs, tokyonight-folke, ... }:
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
xdg.configFile."bat/themes/tokyonight_night.tmTheme".source =
|
||||
"${tokyonight-folke}/extras/sublime/tokyonight_night.tmTheme";
|
||||
programs = {
|
||||
bash.enable = true;
|
||||
bat.enable = true;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ config, pkgs, crafted-emacs, ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
xdg.configFile = {
|
||||
|
@ -10,7 +10,7 @@
|
|||
package = pkgs.emacs29-pgtk;
|
||||
extraConfig = ''
|
||||
(package-initialize)
|
||||
(org-babel-load-file "~/.config/emacs/config.org")
|
||||
(org-babel-load-file (locate-user-emacs-file "config.org"))
|
||||
'';
|
||||
extraPackages = epkgs:
|
||||
with epkgs; [
|
||||
|
|
|
@ -1,180 +0,0 @@
|
|||
;;; $DOOMDIR/config.el -*- lexical-binding: t; -*-
|
||||
|
||||
;; Place your private configuration here! Remember, you do not need to run 'doom
|
||||
;; sync' after modifying this file!
|
||||
|
||||
;; UTF-8 support
|
||||
(prefer-coding-system 'utf-8)
|
||||
(set-default-coding-systems 'utf-8)
|
||||
(set-terminal-coding-system 'utf-8)
|
||||
(set-keyboard-coding-system 'utf-8)
|
||||
(setq x-select-request-type '(UTF8_STRING COMPOUND_TEXT TEXT STRING))
|
||||
|
||||
(setq user-full-name "Evie Litherland-Smith"
|
||||
user-mail-address "e.litherlandsmith@proton.me"
|
||||
doom-font "FiraCode Nerd Font-12"
|
||||
doom-symbol-fallback-font-families '("Material Icons" "FontAwesome" "Weather Icons")
|
||||
doom-emoji-fallback-font-families '("Noto Color Emoji" "Noto Emoji")
|
||||
nerd-icons-font-family "FiraCode Nerd Font"
|
||||
doom-theme 'doom-tokyo-night
|
||||
doom-modeline-gnus t
|
||||
doom-modeline-persp-icon t
|
||||
doom-modeline-persp-name t
|
||||
display-line-numbers-type 'relative
|
||||
org-directory "~/Org/"
|
||||
+latex-viewers '(pdf-tools)
|
||||
+format-with-lsp nil)
|
||||
(+global-word-wrap-mode +1)
|
||||
(setq-default left-margin-width 1 right-margin-width 1)
|
||||
(set-window-buffer nil (current-buffer))
|
||||
(set-frame-parameter nil 'alpha-background 80)
|
||||
(add-to-list 'default-frame-alist '(alpha-background . 80))
|
||||
|
||||
;; DOOM Dashboard customisation
|
||||
(setq +doom-dashboard-menu-sections
|
||||
'(("Recently opened files"
|
||||
:icon (nerd-icons-mdicon "nf-md-file_document" :face 'doom-dashboard-menu-title)
|
||||
:action recentf-open-files)
|
||||
("Reload last session"
|
||||
:icon (nerd-icons-mdicon "nf-md-history" :face 'doom-dashboard-menu-title)
|
||||
:when (cond ((modulep! :ui workspaces)
|
||||
(file-exists-p (expand-file-name persp-auto-save-fname persp-save-dir)))
|
||||
((require 'desktop nil t)
|
||||
(file-exists-p (desktop-full-file-name))))
|
||||
:action doom/quickload-session)
|
||||
("Open org-agenda"
|
||||
:icon (nerd-icons-mdicon "nf-md-calendar" :face 'doom-dashboard-menu-title)
|
||||
:when (fboundp 'org-agenda)
|
||||
:action org-agenda)
|
||||
("Open project"
|
||||
:icon (nerd-icons-mdicon "nf-md-briefcase" :face 'doom-dashboard-menu-title)
|
||||
:action projectile-switch-project)
|
||||
("Jump to bookmark"
|
||||
:icon (nerd-icons-mdicon "nf-md-bookmark" :face 'doom-dashboard-menu-title)
|
||||
:action bookmark-jump)
|
||||
("Open documentation"
|
||||
:icon (nerd-icons-mdicon "nf-md-book" :face 'doom-dashboard-menu-title)
|
||||
:action doom/help)))
|
||||
|
||||
;; elfeed update on open
|
||||
(after! elfeed
|
||||
(setq elfeed-db-directory "~/.elfeed/db/"
|
||||
elfeed-enclosure-default-dir "~/.elfeed/enclosures/")
|
||||
(after! elfeed-goodies
|
||||
(setq elfeed-goodies/entry-pane-position 'bottom
|
||||
elfeed-goodies/powerline-default-separator 'utf-8))
|
||||
(require 'elfeed-tube)
|
||||
(elfeed-tube-setup)
|
||||
(add-hook! 'elfeed-search-mode-hook #'elfeed-update))
|
||||
|
||||
;; ntfy server config
|
||||
(after! ntfy
|
||||
(setq ntfy-server "https://ntfy.xenia.me.uk"
|
||||
ntfy-topic "UhrNGphnSKCpCnk8"
|
||||
ntfy-header "Notification from emacs"
|
||||
ntfy-tags "purple_circle,loudspeaker"))
|
||||
(require 'ntfy)
|
||||
|
||||
;; projectile auto-discover projects
|
||||
(after! projectile
|
||||
(setq projectile-auto-discover t
|
||||
projectile-project-search-path '("~/Projects/")
|
||||
doom-projectile-cache-purge-non-projects t
|
||||
+workspaces-switch-project-function 'doom-project-browse
|
||||
+workspaces-on-switch-project-behavior t))
|
||||
|
||||
(after! magit (setq magit-clone-default-directory "~/Projects/"))
|
||||
|
||||
;; mail settings
|
||||
(after! mu4e
|
||||
(setq mu4e-get-mail-command "mbsync --pull-new inboxes"
|
||||
mu4e-update-interval 300
|
||||
mu4e-sent-messages-behavior 'sent
|
||||
mu4e-attachment-dir "~/Downloads"
|
||||
mu4e-change-filenames-when-moving t
|
||||
mu4e-alert-modeline-formatter 'mu4e-alert-default-mode-line-formatter
|
||||
sendmail-program (executable-find "msmtp")
|
||||
send-mail-function #'smtpmail-send-it
|
||||
message-sendmail-f-is-evil t
|
||||
message-sendmail-extra-arguments '("--read-envelope-from")
|
||||
message-send-mail-function #'message-send-mail-with-sendmail
|
||||
mu4e-maildir-shortcuts '((:maildir "/Proton/Inbox/" :key ?p)
|
||||
(:maildir "/iCloud/Inbox/" :key ?i)
|
||||
(:maildir "/Outlook/Inbox/" :key ?o)))
|
||||
|
||||
(setq mu4e-modeline-all-read '("R:" . " ")
|
||||
mu4e-modeline-all-clear '("C:" . " ")
|
||||
mu4e-modeline-new-items '("N:" . " ")
|
||||
mu4e-modeline-unread-items '("U:" . " ")
|
||||
mu4e-search-full-label '("F" . " ")
|
||||
mu4e-search-hide-label '("H" . " ")
|
||||
mu4e-search-related-label '("R" . " ")
|
||||
mu4e-search-skip-duplicates-label '("D" . " ")
|
||||
mu4e-search-threaded-label'("T" . " "))
|
||||
|
||||
;; Add accounts with contexts
|
||||
(set-email-account! "Proton"
|
||||
'((user-mail-address . "e.litherlandsmith@proton.me")
|
||||
(mu4e-sent-folder . "/Proton/Sent")
|
||||
(mu4e-drafts-folder . "/Proton/Drafts")
|
||||
(mu4e-trash-folder . "/Proton/Trash")
|
||||
(mu4e-refile-folder . "/Proton/Archive"))
|
||||
t)
|
||||
(set-email-account! "iCloud"
|
||||
'((user-mail-address . "e.litherlandsmith@icloud.com")
|
||||
(mu4e-sent-folder . "/iCloud/Sent")
|
||||
(mu4e-drafts-folder . "/iCloud/Drafts")
|
||||
(mu4e-trash-folder . "/iCloud/Trash")
|
||||
(mu4e-refile-folder . "/iCloud/Archive"))
|
||||
nil)
|
||||
(set-email-account! "Outlook"
|
||||
'((user-mail-address . "evie.litherland-smith@ukaea.uk")
|
||||
(mu4e-sent-folder . "/Outlook/Sent")
|
||||
(mu4e-drafts-folder . "/Outlook/Drafts")
|
||||
(mu4e-trash-folder . "/Outlook/Trash")
|
||||
(mu4e-refile-folder . "/Outlook/Archive"))
|
||||
nil)
|
||||
)
|
||||
|
||||
;; Calendar settings
|
||||
(defun open-calendar-all ()
|
||||
(interactive)
|
||||
(cfw:open-calendar-buffer
|
||||
:contents-sources
|
||||
(list
|
||||
(cfw:org-create-source "Green") ; org-agenda source
|
||||
(cfw:ical-create-source "Personal" "~/.calendar/nextcloud/personal.ics" "Red")
|
||||
(cfw:ical-create-source "Birthdays" "~/.calendar/nextcloud/contact_birthdays.ics" "Grey")
|
||||
)))
|
||||
|
||||
;; Org-mode settings
|
||||
(after! org
|
||||
(setq org-agenda-sticky t)
|
||||
(setq org-agenda-files '("~/Org/"))
|
||||
(setq org-agenda-prefix-format
|
||||
'((agenda . " %i %t %s")
|
||||
(todo . " %i")
|
||||
(tags . " %i")
|
||||
(search . " %i"))))
|
||||
|
||||
;; Set org-roam capture templates
|
||||
(after! org-roam
|
||||
(setq org-roam-capture-templates
|
||||
'(("d" "default" plain "%?"
|
||||
:target (file+head "${slug}.org" "#+title: ${title}\n")))))
|
||||
|
||||
;; VTERM settings
|
||||
(after! vterm
|
||||
(setq vterm-tramp-shells
|
||||
'(("ssh" "/usr/bin/env bash")
|
||||
("sshx" "/usr/bin/env bash"))))
|
||||
|
||||
;; Apheleia settings
|
||||
(after! apheleia
|
||||
(setq apheleia-remote-algorithm 'local))
|
||||
|
||||
;; TRAMP host specific configs
|
||||
(after! tramp
|
||||
(setq tramp-default-method "sshx"
|
||||
tramp-default-remote-shell "/bin/sh"
|
||||
tramp-remote-path '(tramp-own-remote-path tramp-default-remote-path)))
|
|
@ -1,12 +0,0 @@
|
|||
(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.
|
||||
'(auth-source-save-behavior nil))
|
||||
(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.
|
||||
'(ts-fold-replacement-face ((t (:foreground unspecified :box nil :inherit font-lock-comment-face :weight light)))))
|
|
@ -1,49 +0,0 @@
|
|||
;;;
|
||||
;;; Recursively list files in a given directory
|
||||
;;;
|
||||
;;; Author: daniel m german dmg at uvic dot ca
|
||||
;;; Copyright: daniel m german
|
||||
;;; License: Same as Emacs
|
||||
;;;
|
||||
(defun directory-files-recursive (directory match maxdepth ignore)
|
||||
"List files in DIRECTORY and in its sub-directories.
|
||||
Return files that match the regular expression MATCH but ignore
|
||||
files and directories that match IGNORE (IGNORE is tested before MATCH.
|
||||
Recurse only to depth MAXDEPTH. If zero or negative, then do not recurse"
|
||||
(let* ((files-list '())
|
||||
(current-directory-list
|
||||
(directory-files directory t)))
|
||||
;; while we are in the current directory
|
||||
(while current-directory-list
|
||||
(let ((f (car current-directory-list)))
|
||||
(cond
|
||||
((and
|
||||
ignore ;; make sure it is not nil
|
||||
(string-match ignore f))
|
||||
; ignore
|
||||
nil
|
||||
)
|
||||
((and
|
||||
(file-regular-p f)
|
||||
(file-readable-p f)
|
||||
(string-match match f))
|
||||
(setq files-list (cons f files-list))
|
||||
)
|
||||
((and
|
||||
(file-directory-p f)
|
||||
(file-readable-p f)
|
||||
(not (string-equal ".." (substring f -2)))
|
||||
(not (string-equal "." (substring f -1)))
|
||||
(> maxdepth 0))
|
||||
;; recurse only if necessary
|
||||
(setq files-list (append files-list (directory-files-recursive f match (- maxdepth -1) ignore)))
|
||||
(setq files-list (cons f files-list))
|
||||
)
|
||||
(t)
|
||||
)
|
||||
)
|
||||
(setq current-directory-list (cdr current-directory-list))
|
||||
)
|
||||
files-list
|
||||
)
|
||||
)
|
|
@ -1,154 +0,0 @@
|
|||
;;; init.el -*- lexical-binding: t; -*-
|
||||
|
||||
;; This file controls what Doom modules are enabled and what order they load
|
||||
;; in. Remember to run 'doom sync' after modifying it!
|
||||
|
||||
;; NOTE Press 'SPC h d h' (or 'C-h d h' for non-vim users) to access Doom's
|
||||
;; documentation. There you'll find a "Module Index" link where you'll find
|
||||
;; a comprehensive list of Doom's modules and what flags they support.
|
||||
|
||||
;; NOTE Move your cursor over a module's name (or its flags) and press 'K' (or
|
||||
;; 'C-c c k' for non-vim users) to view its documentation. This works on
|
||||
;; flags as well (those symbols that start with a plus).
|
||||
;;
|
||||
;; Alternatively, press 'gd' (or 'C-c c d') on a module to browse its
|
||||
;; directory (for easy access to its source code).
|
||||
|
||||
;;; Code:
|
||||
(doom! :completion
|
||||
company ; the ultimate code completion backend
|
||||
(vertico +icons) ; the search engine of the future
|
||||
|
||||
:ui
|
||||
doom ; what makes DOOM look the way it does
|
||||
doom-dashboard ; a nifty splash screen for Emacs
|
||||
doom-quit ; DOOM quit-message prompts when you quit Emacs
|
||||
;; (emoji +github) ; 🙂
|
||||
hl-todo ; highlight TODO/FIXME/NOTE/DEPRECATED/HACK/REVIEW
|
||||
indent-guides ; highlighted indent columns
|
||||
ligatures ; ligatures and symbols to make your code pretty again
|
||||
modeline ; snazzy, Atom-inspired modeline, plus API
|
||||
(popup +defaults) ; tame sudden yet inevitable temporary windows
|
||||
treemacs ; a project drawer, like neotree but cooler
|
||||
;; unicode ; extended unicode support for various languages
|
||||
vc-gutter ; vcs diff in the fringe
|
||||
window-select ; visually switch windows
|
||||
workspaces ; tab emulation, persistence & separate workspaces
|
||||
zen ; distraction-free coding or writing
|
||||
|
||||
:editor
|
||||
;; (evil +everywhere) ; come to the dark side, we have cookies
|
||||
file-templates ; auto-snippets for empty files
|
||||
fold ; (nigh) universal code folding
|
||||
(format +onsave) ; automated prettiness
|
||||
snippets ; my elves. They type so I don't have to
|
||||
word-wrap ; soft wrapping with language-aware indent
|
||||
|
||||
:emacs
|
||||
(dired +icons) ; making dired pretty [functional]
|
||||
electric ; smarter, keyword-based electric-indent
|
||||
(ibuffer +icons) ; interactive buffer management
|
||||
undo ; persistent, smarter undo for your inevitable mistakes
|
||||
vc ; version-control and Emacs, sitting in a tree
|
||||
|
||||
:term
|
||||
eshell ; the elisp shell that works everywhere
|
||||
vterm ; the best terminal emulation in Emacs
|
||||
|
||||
:checkers
|
||||
syntax ; tasing you for every semicolon you forget
|
||||
(spell +flyspell) ; tasing you for misspelling mispelling
|
||||
grammar ; tasing grammar mistake every you make
|
||||
|
||||
:tools
|
||||
biblio ; Writes a PhD for you (citation needed)
|
||||
direnv
|
||||
(docker +lsp)
|
||||
(eval +overlay) ; run code, run (also, repls)
|
||||
(lookup +dictionary +offline) ; navigate your code and its documentation
|
||||
(lsp +eglot) ; M-x vscode
|
||||
magit ; a git porcelain for Emacs
|
||||
make ; run make tasks from Emacs
|
||||
(pass +auth) ; password manager for nerds
|
||||
pdf ; pdf enhancements
|
||||
tree-sitter ; Better syntax highlighting
|
||||
upload ; map local to remote projects via ssh/ftp
|
||||
|
||||
:os
|
||||
(:if IS-MAC macos) ; improve compatibility with macOS
|
||||
tty ; improve the terminal Emacs experience
|
||||
|
||||
:lang
|
||||
;; agda ; types of types of types of types...
|
||||
;; beancount ; mind the GAAP
|
||||
;; cc ; C > C++ == 1
|
||||
;; clojure ; java with a lisp
|
||||
;; common-lisp ; if you've seen one lisp, you've seen them all
|
||||
;; coq ; proofs-as-programs
|
||||
;; crystal ; ruby at the speed of c
|
||||
;; csharp ; unity, .NET, and mono shenanigans
|
||||
data ; config/data formats
|
||||
;; (dart +flutter) ; paint ui and not much else
|
||||
;; dhall
|
||||
;; elixir ; erlang done right
|
||||
;; elm ; care for a cup of TEA?
|
||||
emacs-lisp ; drown in parentheses
|
||||
;; erlang ; an elegant language for a more civilized age
|
||||
;; ess ; emacs speaks statistics
|
||||
;; factor
|
||||
;; faust ; dsp, but you get to keep your soul
|
||||
(fortran +lsp) ; in FORTRAN, GOD is REAL (unless declared INTEGER)
|
||||
;; fsharp ; ML stands for Microsoft's Language
|
||||
;; fstar ; (dependent) types and (monadic) effects and Z3
|
||||
;; gdscript ; the language you waited for
|
||||
;; (go +lsp) ; the hipster dialect
|
||||
;; (haskell +lsp) ; a language that's lazier than I am
|
||||
;; hy ; readability of scheme w/ speed of python
|
||||
;; idris ; a language you can depend on
|
||||
;; json ; At least it ain't XML
|
||||
;; (java +meghanada) ; the poster child for carpal tunnel syndrome
|
||||
;; javascript ; all(hope(abandon(ye(who(enter(here))))))
|
||||
;; julia ; a better, faster MATLAB
|
||||
;; kotlin ; a better, slicker Java(Script)
|
||||
(latex +lsp) ; writing papers in Emacs has never been so fun
|
||||
;; lean ; for folks with too much to prove
|
||||
;; ledger ; be audit you can be
|
||||
(lua +lsp +tree-sitter) ; one-based indices? one-based indices
|
||||
markdown ; writing docs for people to ignore
|
||||
;; nim ; python + lisp at the speed of c
|
||||
(nix +lsp +tree-sitter) ; I hereby declare "nix geht mehr!"
|
||||
;; ocaml ; an objective camel
|
||||
(org +roam2 +noter +pretty +present +pandoc) ; organize your plain life in plain text
|
||||
;; php ; perl's insecure younger brother
|
||||
;; plantuml ; diagrams for confusing people more
|
||||
;; purescript ; javascript, but functional
|
||||
(python +lsp +tree-sitter +pyright +cython) ; beautiful is better than ugly
|
||||
;; qt ; the 'cutest' gui framework ever
|
||||
;; racket ; a DSL for DSLs
|
||||
;; raku ; the artist formerly known as perl6
|
||||
;; rest ; Emacs as a REST client
|
||||
;; rst ; ReST in peace
|
||||
;; (ruby +rails) ; 1.step {|i| p "Ruby is #{i.even? ? 'love' : 'life'}"}
|
||||
(rust +lsp +tree-sitter) ; Fe2O3.unwrap().unwrap().unwrap().unwrap()
|
||||
;; scala ; java, but good
|
||||
;; (scheme +guile) ; a fully conniving family of lisps
|
||||
(sh +lsp +tree-sitter) ; she sells {ba,z,fi}sh shells on the C xor
|
||||
;; sml
|
||||
;; solidity ; do you need a blockchain? No.
|
||||
;; swift ; who asked for emoji variables?
|
||||
;; terra ; Earth and Moon in alignment for performance.
|
||||
(web +lsp +tree-sitter) ; the tubes
|
||||
(yaml +lsp +tree-sitter) ; JSON, but readable
|
||||
;; zig ; C, but simpler
|
||||
|
||||
:email
|
||||
(mu4e +org +gmail)
|
||||
|
||||
:app
|
||||
calendar
|
||||
emms
|
||||
(rss +org)
|
||||
;; irc ; how neckbeards socialize
|
||||
|
||||
:config
|
||||
(default +bindings +smartparens))
|
|
@ -1,10 +0,0 @@
|
|||
;; -*- no-byte-compile: t; -*-
|
||||
;;; $DOOMDIR/packages.el
|
||||
|
||||
(package! pdf-tools
|
||||
:built-in 'prefer)
|
||||
(package! pocket-reader)
|
||||
(package! elfeed-tube)
|
||||
(package! mpv)
|
||||
(package! ntfy
|
||||
:recipe (:host sourcehut :repo "shom/ntfy"))
|
|
@ -1,57 +0,0 @@
|
|||
;;; init.el -*- lexical-binding: t; -*-
|
||||
|
||||
;;; Initial phase.
|
||||
|
||||
;; Load the custom file if it exists. Among other settings, this will
|
||||
;; have the list `package-selected-packages', so we need to load that
|
||||
;; before adding more packages. The value of the `custom-file'
|
||||
;; variable must be set appropriately, by default the value is nil.
|
||||
;; This can be done here, or in the early-init.el file.
|
||||
(setq custom-file (locate-user-emacs-file "custom.el"))
|
||||
(when (and custom-file (file-exists-p custom-file))
|
||||
(load custom-file nil 'nomessage))
|
||||
|
||||
;; Setup package-archives and priorities
|
||||
(when (require 'package nil :noerror)
|
||||
(add-to-list 'package-archives '("stable" . "https://stable.melpa.org/packages/"))
|
||||
(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/"))
|
||||
|
||||
(setq package-archive-priorities '(("gnu" . 99)
|
||||
("nongnu" . 80)
|
||||
("stable" . 70)
|
||||
("melpa" . 0))))
|
||||
|
||||
;; Add custom modules to the `load-path'
|
||||
(add-to-list 'load-path (expand-file-name "modules" user-emacs-directory))
|
||||
|
||||
;; Adds crafted-emacs modules to the `load-path'
|
||||
(setq crafted-emacs-home (expand-file-name "crafted-emacs" user-emacs-directory))
|
||||
(add-to-list 'load-path (expand-file-name "modules" crafted-emacs-home))
|
||||
|
||||
;;; Configuration phase
|
||||
|
||||
(setq user-full-name "Evie Litherland-Smith"
|
||||
user-mail-address "evie@xenia.me.uk")
|
||||
|
||||
;; Set default coding system (especially for Windows)
|
||||
(set-default-coding-systems 'utf-8)
|
||||
(set-terminal-coding-system 'utf-8)
|
||||
(set-keyboard-coding-system 'utf-8)
|
||||
|
||||
(require 'custom-defaults-config)
|
||||
(pcase system-type ('gnu/linux (require 'custom-ui-config)))
|
||||
|
||||
(require 'custom-email-config)
|
||||
(require 'custom-feed-config)
|
||||
(require 'custom-ide-config)
|
||||
(require 'custom-ligatures-config)
|
||||
(require 'custom-media-config)
|
||||
(require 'custom-org-config)
|
||||
(require 'custom-project-config)
|
||||
(require 'custom-social-config)
|
||||
|
||||
(require 'crafted-completion-config)
|
||||
(require 'crafted-ide-config)
|
||||
(require 'crafted-org-config)
|
||||
(require 'crafted-workspaces-config)
|
||||
(require 'crafted-writing-config)
|
|
@ -1,40 +0,0 @@
|
|||
;;; custom-defaults-config.el -*- lexical-binding: t; -*-
|
||||
|
||||
;;; Code:
|
||||
(setq load-prefer-newer t
|
||||
indent-tabs-mode nil
|
||||
global-auto-revert-non-file-buffers t
|
||||
dired-auto-revert-buffer t
|
||||
dired-dwim-target t
|
||||
tab-always-indent 'complete
|
||||
completion-cycle-threshold 3
|
||||
completions-detailed t
|
||||
xref-show-definitions-function #'xref-show-definitions-completing-read
|
||||
kill-do-not-save-duplicates t
|
||||
auto-window-vscroll nil
|
||||
fast-but-imprecise-scrolling t
|
||||
scroll-conservatively 101
|
||||
scroll-margin 0
|
||||
scroll-preserve-screen-position 1)
|
||||
|
||||
(global-auto-revert-mode +1)
|
||||
(delete-selection-mode)
|
||||
|
||||
;; Misc useful keymaps
|
||||
(keymap-global-set "M-#" #'dictionary-lookup-definition)
|
||||
(keymap-global-set "C-c r" #'recentf)
|
||||
(keymap-global-set "C-c b" #'ibuffer)
|
||||
(keymap-global-set "C-c p l" #'list-packages)
|
||||
(keymap-global-set "C-c p r" #'package-refresh-contents)
|
||||
(keymap-global-set "C-c p i" #'package-install)
|
||||
(keymap-global-set "C-c p d" #'package-delete)
|
||||
|
||||
;; turn on spell checking, if available.
|
||||
(when (and (require 'ispell nil :noerror) (executable-find ispell-program-name))
|
||||
(add-hook 'text-mode-hook #'flyspell-mode)
|
||||
(add-hook 'prog-mode-hook #'flyspell-prog-mode))
|
||||
|
||||
;; Make shebang (#!) file executable when saved
|
||||
(add-hook 'after-save-hook #'executable-make-buffer-file-executable-if-script-p)
|
||||
|
||||
(provide 'custom-defaults-config)
|
|
@ -1,70 +0,0 @@
|
|||
(setq sendmail-program (executable-find "msmtp")
|
||||
send-mail-function #'smtpmail-send-it
|
||||
message-sendmail-f-is-evil t
|
||||
message-sendmail-extra-arguments '("--read-envelope-from")
|
||||
message-send-mail-function #'message-send-mail-with-sendmail
|
||||
message-kill-buffer-on-exit t
|
||||
mail-user-agent 'mu4e-user-agent
|
||||
read-mail-command 'mu4e
|
||||
mu4e-maildir "~/Mail"
|
||||
mu4e-attachment-dir "~/Downloads"
|
||||
mu4e-get-mail-command "mbsync -a"
|
||||
mu4e-update-interval (* 5 60) ; Every 5 minutes
|
||||
mu4e-sent-messages-behavior 'sent
|
||||
mu4e-change-filenames-when-moving t
|
||||
mu4e-context-policy 'pick-first
|
||||
mu4e-headers-fields '((:human-date . 12)
|
||||
(:flags . 6)
|
||||
(:from-or-to . 25)
|
||||
(:subject))
|
||||
mu4e-headers-actions '(("org capture message" . mu4e-org-store-and-capture)
|
||||
("capture message" . mu4e-action-capture-message)
|
||||
("show this thread" . mu4e-action-show-thread))
|
||||
mu4e-maildir-shortcuts '((:maildir "/Proton/Inbox/" :key ?p)
|
||||
(:maildir "/iCloud/Inbox/" :key ?i)
|
||||
(:maildir "/Outlook/Inbox/" :key ?w)))
|
||||
|
||||
(when (require 'mu4e nil :noerror)
|
||||
(keymap-global-set "C-c m m" #'mu4e)
|
||||
(keymap-global-set "C-c m u" #'mu4e-update-index)
|
||||
(keymap-global-set "C-c m c" #'mu4e-compose-new)
|
||||
|
||||
(when (require 'mu4e-alert nil :noerror)
|
||||
(mu4e-alert-set-default-style 'libnotify)
|
||||
(mu4e-alert-enable-notifications)
|
||||
(mu4e-alert-enable-mode-line-display))
|
||||
|
||||
(setq mu4e-contexts (list
|
||||
(make-mu4e-context
|
||||
:name "Xenia"
|
||||
:vars '((user-mail-address . "evie@xenia.me.uk")
|
||||
(mu4e-sent-folder . "/Proton/Sent")
|
||||
(mu4e-drafts-folder . "/Proton/Drafts")
|
||||
(mu4e-trash-folder . "/Proton/Trash")
|
||||
(mu4e-refile-folder . "/Proton/Archive")))
|
||||
(make-mu4e-context
|
||||
:name "Proton"
|
||||
:match-func (lambda (msg) (when msg (string-prefix-p "/Proton" (mu4e-message-field msg :maildir))))
|
||||
:vars '((user-mail-address . "e.litherlandsmith@proton.me")
|
||||
(mu4e-sent-folder . "/Proton/Sent")
|
||||
(mu4e-drafts-folder . "/Proton/Drafts")
|
||||
(mu4e-trash-folder . "/Proton/Trash")
|
||||
(mu4e-refile-folder . "/Proton/Archive")))
|
||||
(make-mu4e-context
|
||||
:name "iCloud"
|
||||
:match-func (lambda (msg) (when msg (string-prefix-p "/iCloud" (mu4e-message-field msg :maildir))))
|
||||
:vars '((user-mail-address . "e.litherlandsmith@icloud.com")
|
||||
(mu4e-sent-folder . "/iCloud/Sent Messages")
|
||||
(mu4e-drafts-folder . "/iCloud/Drafts")
|
||||
(mu4e-trash-folder . "/iCloud/Deleted Messages")
|
||||
(mu4e-refile-folder . "/iCloud/Archive")))
|
||||
(make-mu4e-context
|
||||
:name "Work"
|
||||
:match-func (lambda (msg) (when msg (string-prefix-p "/Outlook" (mu4e-message-field msg :maildir))))
|
||||
:vars '((user-mail-address . "evie.litherland-smith@ukaea.uk")
|
||||
(mu4e-sent-folder . "/Outlook/Sent")
|
||||
(mu4e-drafts-folder . "/Outlook/Drafts")
|
||||
(mu4e-trash-folder . "/Outlook/Trash")
|
||||
(mu4e-refile-folder . "/Outlook/Archive"))))))
|
||||
|
||||
(provide 'custom-email-config)
|
|
@ -1,14 +0,0 @@
|
|||
(let ((elfeed-base-directory "~/.elfeed"))
|
||||
(setq elfeed-db-directory (expand-file-name "db" elfeed-base-directory)
|
||||
elfeed-enclosure-default-dir (expand-file-name "enclosures" elfeed-base-directory)
|
||||
rmh-elfeed-org-files (list (expand-file-name "feeds.org" elfeed-base-directory))))
|
||||
|
||||
(when (require 'elfeed nil :noerror)
|
||||
(keymap-global-set "C-c f f" #'elfeed)
|
||||
(add-hook 'elfeed-search-mode-hook #'elfeed-update)
|
||||
(when (require 'elfeed-org nil :noerror)
|
||||
(elfeed-org))
|
||||
(when (require 'elfeed-tube nil :noerror)
|
||||
(elfeed-tube-setup)))
|
||||
|
||||
(provide 'custom-feed-config)
|
|
@ -1,24 +0,0 @@
|
|||
(when (require 'rainbow-delimiters nil :noerror)
|
||||
(add-hook 'prog-mode-hook #'rainbow-delimiters-mode))
|
||||
|
||||
(when (require 'treesit-aut nil :noerror)
|
||||
(global-treesit-auto-mode +1))
|
||||
|
||||
(setq apheleia-remote-algorithm 'local)
|
||||
(when (require 'apheleia nil :noerror)
|
||||
(keymap-global-set "C-c c f" #'apheleia-format-buffer)
|
||||
(apheleia-global-mode +1))
|
||||
|
||||
(when (require 'eglot nil :noerror)
|
||||
(eglot-ensure))
|
||||
|
||||
(setq direnv-always-show-summary nil)
|
||||
(when (require 'direnv nil :noerror)
|
||||
(direnv-mode +1))
|
||||
|
||||
(when (require 'yasnippet nil :noerror)
|
||||
(require 'yasnippet-snippets nil :noerror)
|
||||
(yas-reload-all)
|
||||
(add-hook 'prog-mode-hook #'yas-minor-mode))
|
||||
|
||||
(provide 'custom-ide-config)
|
|
@ -1,60 +0,0 @@
|
|||
(defun fira-code-mode--make-alist (list)
|
||||
"Generate prettify-symbols alist from LIST."
|
||||
(let ((idx -1))
|
||||
(mapcar
|
||||
(lambda (s)
|
||||
(setq idx (1+ idx))
|
||||
(let* ((code (+ #Xe100 idx))
|
||||
(width (string-width s))
|
||||
(prefix ())
|
||||
(suffix '(?\s (Br . Br)))
|
||||
(n 1))
|
||||
(while (< n width)
|
||||
(setq prefix (append prefix '(?\s (Br . Bl))))
|
||||
(setq n (1+ n)))
|
||||
(cons s (append prefix suffix (list (decode-char 'ucs code))))))
|
||||
list)))
|
||||
|
||||
(defconst fira-code-mode--ligatures
|
||||
'("www" "**" "***" "**/" "*>" "*/" "\\\\" "\\\\\\"
|
||||
"{-" "[]" "::" ":::" ":=" "!!" "!=" "!==" "-}"
|
||||
"--" "---" "-->" "->" "->>" "-<" "-<<" "-~"
|
||||
"#{" "#[" "##" "###" "####" "#(" "#?" "#_" "#_("
|
||||
".-" ".=" ".." "..<" "..." "?=" "??" ";;" "/*"
|
||||
"/**" "/=" "/==" "/>" "//" "///" "&&" "||" "||="
|
||||
"|=" "|>" "^=" "$>" "++" "+++" "+>" "=:=" "=="
|
||||
"===" "==>" "=>" "=>>" "<=" "=<<" "=/=" ">-" ">="
|
||||
">=>" ">>" ">>-" ">>=" ">>>" "<*" "<*>" "<|" "<|>"
|
||||
"<$" "<$>" "<!--" "<-" "<--" "<->" "<+" "<+>" "<="
|
||||
"<==" "<=>" "<=<" "<>" "<<" "<<-" "<<=" "<<<" "<~"
|
||||
"<~~" "</" "</>" "~@" "~-" "~=" "~>" "~~" "~~>" "%%"
|
||||
"x" ":" "+" "+" "*"))
|
||||
|
||||
(defvar fira-code-mode--old-prettify-alist)
|
||||
|
||||
(defun fira-code-mode--enable ()
|
||||
"Enable Fira Code ligatures in current buffer."
|
||||
(setq-local fira-code-mode--old-prettify-alist prettify-symbols-alist)
|
||||
(setq-local prettify-symbols-alist (append (fira-code-mode--make-alist fira-code-mode--ligatures) fira-code-mode--old-prettify-alist))
|
||||
(prettify-symbols-mode t))
|
||||
|
||||
(defun fira-code-mode--disable ()
|
||||
"Disable Fira Code ligatures in current buffer."
|
||||
(setq-local prettify-symbols-alist fira-code-mode--old-prettify-alist)
|
||||
(prettify-symbols-mode -1))
|
||||
|
||||
(define-minor-mode fira-code-mode
|
||||
"Fira Code ligatures minor mode"
|
||||
:lighter " Fira Code"
|
||||
(setq-local prettify-symbols-unprettify-at-point 'right-edge)
|
||||
(if fira-code-mode
|
||||
(fira-code-mode--enable)
|
||||
(fira-code-mode--disable)))
|
||||
|
||||
(defun fira-code-mode--setup ()
|
||||
"Setup Fira Code Symbols"
|
||||
(set-fontset-font t '(#Xe100 . #Xe16f) "Fira Code Symbol"))
|
||||
|
||||
(fira-code-mode)
|
||||
|
||||
(provide 'custom-ligatures-config)
|
|
@ -1,23 +0,0 @@
|
|||
(when (require 'emms-setup nil :noerror)
|
||||
(setq emms-player-list '(emms-player-mpv)
|
||||
emms-info-functions '(emms-info-native)
|
||||
emms-source-file-default-directory "~/Music"
|
||||
emms-lyrics-dir "~/Music/lyrics"
|
||||
emms-mode-line-icon-color "white")
|
||||
|
||||
(emms-all)
|
||||
(add-hook 'emms-player-started-hook #'emms-show)
|
||||
(add-hook 'emms-player-paused-hook #'emms-show)
|
||||
|
||||
(when (require 'hydra nil :noerror)
|
||||
(defhydra emms (global-map "C-c e")
|
||||
"emms"
|
||||
("b" emms-smart-browse)
|
||||
("d" emms-show)
|
||||
("s" emms-start)
|
||||
("S" emms-stop)
|
||||
("n" emms-next)
|
||||
("p" emms-previous)
|
||||
("P" emms-pause))))
|
||||
|
||||
(provide 'custom-media-config)
|
|
@ -1,66 +0,0 @@
|
|||
(setq org-directory "~/Org"
|
||||
org-pretty-entities t
|
||||
org-pretty-entities-include-sub-superscripts t
|
||||
org-tags-column 0
|
||||
org-modern-tag nil
|
||||
org-agenda-files '("~/Org/" "~/Org/journal/" "~/Org/projects/")
|
||||
org-agenda-sticky t
|
||||
org-agenda-window-setup 'current-window
|
||||
org-agenda-prefix-format '((agenda . " %-12:c%?-12t% s")
|
||||
(todo . " %-12:c")
|
||||
(tags . " %-12:c")
|
||||
(search . " %-12:c"))
|
||||
org-journal-dir (expand-file-name "journal" org-directory)
|
||||
org-journal-file-type 'monthly
|
||||
org-journal-file-format "%Y-%m.org"
|
||||
org-refile-use-outline-path t
|
||||
org-refile-allow-creating-parent-nodes t
|
||||
org-refile-use-outline-path 'file
|
||||
org-refile-targets '((nil :maxlevel . 3)
|
||||
(org-agenda-files :maxlevel . 3))
|
||||
org-outline-path-complete-in-steps nil
|
||||
org-default-notes-file (expand-file-name "notes.org" org-directory))
|
||||
|
||||
(keymap-global-set "C-c o a" #'org-agenda)
|
||||
(keymap-global-set "C-c o n" #'org-capture)
|
||||
(keymap-global-set "C-c o l" #'org-capture-goto-last-stored)
|
||||
(keymap-global-set "C-c o j j" #'org-journal-new-entry)
|
||||
(keymap-global-set "C-c o j n" #'org-journal-new-date-entry)
|
||||
(keymap-global-set "C-c o j s" #'org-journal-new-scheduled-entry)
|
||||
|
||||
(add-hook 'org-mode-hook #'org-modern-mode)
|
||||
(add-hook 'org-agenda-finalize-hook #'org-modern-agenda)
|
||||
|
||||
(setq org-capture-templates
|
||||
'(("n" "Note" entry
|
||||
(file+headline "inbox.org" "Note")
|
||||
"* %?"
|
||||
:prepend t
|
||||
:empty-lines 1)
|
||||
("t" "Task" entry
|
||||
(file+headline "inbox.org" "Task")
|
||||
"* TODO %?"
|
||||
:prepend t
|
||||
:empty-lines 1)
|
||||
))
|
||||
|
||||
(setq citar-bibliography '("~/.references/main.bib")
|
||||
citar-library-paths '("~/.references/library")
|
||||
citar-notes-paths '("~/.references/notes")
|
||||
citar-symbols '((file "F" . "")
|
||||
(note "N" . "")
|
||||
(link "L" . "")))
|
||||
(when (require 'citar nil :noerror)
|
||||
(keymap-global-set "C-c o c o" #'citar-open)
|
||||
(keymap-global-set "C-c o c a" #'citar-add-file-to-library))
|
||||
|
||||
(setq khalel-import-org-file (expand-file-name "calendar.org" org-directory)
|
||||
khalel-import-org-file-read-only nil
|
||||
khalel-import-org-file-confirm-overwrite nil
|
||||
khalel-import-start-date "-30d"
|
||||
khalel-import-end-date "+30d")
|
||||
(when (require 'khalel nil :noerror)
|
||||
(add-hook 'org-agenda-mode-hook #'khalel-import-events)
|
||||
(khalel-add-capture-template "e"))
|
||||
|
||||
(provide 'custom-org-config)
|
|
@ -1,12 +0,0 @@
|
|||
(setq project-switch-use-entire-map t
|
||||
project-switch-commands
|
||||
'((project-dired "Browse directory")
|
||||
(project-find-file "Find file")
|
||||
(project-find-regexp "Find regexp")
|
||||
(project-find-dir "Find directory")
|
||||
(project-eshell "Eshell")))
|
||||
|
||||
(setq magit-clone-default-directory "~/Projects/")
|
||||
(require 'magit nil :noerror)
|
||||
|
||||
(provide 'custom-project-config)
|
|
@ -1,5 +0,0 @@
|
|||
(setq mastodon-instance-url "https://tech.lgbt"
|
||||
mastodon-active-user "Tux922")
|
||||
(require 'mastodon nil :noerror)
|
||||
|
||||
(provide 'custom-social-config)
|
|
@ -1,140 +0,0 @@
|
|||
;;; custom-ui-config.el -*- lexical-binding: t; -*-
|
||||
|
||||
;; Copyright (C) 2023
|
||||
;; SPDX-License-Identifier: MIT
|
||||
|
||||
;; Author: System Crafters Community
|
||||
|
||||
;;; Code:
|
||||
|
||||
(setq use-dialog-box nil
|
||||
fill-column 80
|
||||
truncate-lines nil
|
||||
truncate-partial-width-windows nil)
|
||||
|
||||
(menu-bar-mode -1)
|
||||
(tab-bar-mode -1)
|
||||
(tool-bar-mode -1)
|
||||
(scroll-bar-mode -1)
|
||||
(line-number-mode)
|
||||
(global-display-line-numbers-mode -1)
|
||||
(global-prettify-symbols-mode +1)
|
||||
(global-visual-line-mode +1)
|
||||
;; (set-frame-font "FiraCode Nerd Font-12")
|
||||
;; (set-frame-parameter nil 'alpha-background 80)
|
||||
|
||||
;; Nerd-Icons modes
|
||||
(when (require 'nerd-icons)
|
||||
(nerd-icons-set-font "Symbols Nerd Font Mono")
|
||||
(when (require 'nerd-icons-dired nil :noerror)
|
||||
(add-hook 'dired-mode-hook #'nerd-icons-dired-mode))
|
||||
|
||||
(when (require 'nerd-icons-ibuffer nil :noerror)
|
||||
(add-hook 'ibuffer-mode-hook #'nerd-icons-ibuffer-mode))
|
||||
|
||||
(when (require 'nerd-icons-completion nil :noerror)
|
||||
(nerd-icons-completion-mode)
|
||||
(when (require 'marginalia nil :noerror)
|
||||
(add-hook 'marginalia-mode-hook #'nerd-icons-completion-marginalia-setup))))
|
||||
|
||||
;; Doom-Modeline
|
||||
(setq doom-modeline-icon t
|
||||
doom-modeline-mu4e nil ;; Use mu4e own formatting
|
||||
doom-modeline-modal nil
|
||||
doom-modeline-modal-icon nil
|
||||
doom-modeline-persp-name nil
|
||||
doom-modeline-persp-icon nil)
|
||||
(when (require 'doom-modeline nil :noerror)
|
||||
(doom-modeline-mode +1))
|
||||
|
||||
(setq mu4e-use-fancy-chars t
|
||||
mu4e-headers-thread-single-orphan-prefix '("─>" . "─▶")
|
||||
mu4e-headers-thread-orphan-prefix '("┬>" . "┬▶")
|
||||
mu4e-headers-thread-connection-prefix '("│ " . "│ ")
|
||||
mu4e-headers-thread-first-child-prefix '("├>" . "├▶")
|
||||
mu4e-headers-thread-child-prefix '("├>" . "├▶")
|
||||
mu4e-headers-thread-last-child-prefix '("└>" . "╰▶")
|
||||
mu4e-modeline-all-read '("R:" . ":")
|
||||
mu4e-modeline-all-clear '("C:" . ":")
|
||||
mu4e-modeline-new-items '("N:" . ":")
|
||||
mu4e-modeline-unread-items '("U:" . ":")
|
||||
mu4e-search-full-label '("F" . "")
|
||||
mu4e-search-hide-label '("H" . "")
|
||||
mu4e-search-related-label '("R" . "")
|
||||
mu4e-search-skip-duplicates-label '("D" . "")
|
||||
mu4e-search-threaded-label'("T" . "")
|
||||
mu4e-alert-modeline-formatter 'mu4e-alert-default-mode-line-formatter)
|
||||
|
||||
;; Dashboard
|
||||
(setq initial-buffer-choice 'dashboard-open
|
||||
dashboard-icon-type 'nerd-icons
|
||||
dashboard-set-heading-icons t
|
||||
dashboard-set-file-icons t
|
||||
dashboard-set-navigator t
|
||||
dashboard-set-init-info t
|
||||
dashboard-startup-banner 'ascii
|
||||
dashboard-projects-backend 'project-el
|
||||
dashboard-projects-switch-function 'project-switch-project
|
||||
dashboard-projects-show-base t
|
||||
dashboard-recentf-show-base 'align
|
||||
dashboard-items '((recents . 5)
|
||||
(agenda . 15))
|
||||
dashboard-heading-icons '((recents . "nf-oct-history")
|
||||
(agenda . "nf-oct-calendar"))
|
||||
dashboard-banner-ascii (concat " .000000. \n"
|
||||
" .0. .0. \n"
|
||||
" .00. .00. \n"
|
||||
" .000cl. .lc000. \n"
|
||||
".0 0.\n"
|
||||
"0. .o0000o. .0\n"
|
||||
" 00 .0' '0. 00 \n"
|
||||
" 00 .0 0. 00 \n"
|
||||
" HHHHH HHHHHHHHHHHH HHHHH \n"
|
||||
"HHHH HHH HHHHHHHHHHHHHH HHHH\n"
|
||||
" HHHHHH HHHHHHHHH HHHHHHHH \n"
|
||||
" HHH HHHH HHHHHHHHH HHHH \n"
|
||||
" HHH HHHHHH \n"
|
||||
" HHHHH HH \n"))
|
||||
(when (require 'dashboard nil :noerror)
|
||||
(keymap-global-set "C-c d" #'dashboard-open)
|
||||
(add-hook 'dashboard-mode-hook #'khalel-import-events))
|
||||
|
||||
;; Extra minor-modes
|
||||
(when (require 'git-gutter nil :noerror)
|
||||
(global-git-gutter-mode +1))
|
||||
|
||||
(when (require 'which-key nil :noerror)
|
||||
(which-key-mode +1))
|
||||
|
||||
(when (require 'page-break-lines nil :noerror)
|
||||
(global-page-break-lines-mode +1))
|
||||
|
||||
;;;; Help Buffers
|
||||
|
||||
;; Make `describe-*' screens more helpful
|
||||
(when (require 'helpful nil :noerror)
|
||||
(keymap-set helpful-mode-map "<remap> <revert-buffer>" #'helpful-update)
|
||||
(keymap-global-set "<remap> <describe-command>" #'helpful-command)
|
||||
(keymap-global-set "<remap> <describe-function>" #'helpful-callable)
|
||||
(keymap-global-set "<remap> <describe-key>" #'helpful-key)
|
||||
(keymap-global-set "<remap> <describe-symbol>" #'helpful-symbol)
|
||||
(keymap-global-set "<remap> <describe-variable>" #'helpful-variable)
|
||||
(keymap-global-set "C-h F" #'helpful-function))
|
||||
|
||||
;; Bind extra `describe-*' commands
|
||||
(keymap-global-set "C-h K" #'describe-keymap)
|
||||
|
||||
;; add visual pulse when changing focus, like beacon but built-in
|
||||
;; from from https://karthinks.com/software/batteries-included-with-emacs/
|
||||
(defun pulse-line (&rest _)
|
||||
"Pulse the current line."
|
||||
(pulse-momentary-highlight-one-line (point)))
|
||||
|
||||
(dolist (command '(scroll-up-command
|
||||
scroll-down-command
|
||||
recenter-top-bottom
|
||||
other-window))
|
||||
(advice-add command :after #'pulse-line))
|
||||
|
||||
(provide 'custom-ui-config)
|
||||
;;; custom-ui-config.el ends here
|
Loading…
Reference in a new issue