Try to fix borked org config #emacs
This commit is contained in:
16
emacs/.config/doom/+magit.el
Normal file
16
emacs/.config/doom/+magit.el
Normal file
@ -0,0 +1,16 @@
|
||||
;;; ~/.doom.d/+magit.el -*- lexical-binding: t; -*-
|
||||
|
||||
(setq +magit-hub-features t ;; I want the PR/issue stuff too!
|
||||
+magit-hub-enable-by-default t) ;; And I want it on by default!
|
||||
|
||||
(after! magit
|
||||
(magit-wip-after-save-mode t)
|
||||
(magit-wip-after-apply-mode t)
|
||||
|
||||
(setq magit-save-repository-buffers 'dontask
|
||||
magit-repository-directories '(("~/src/" . 3)
|
||||
("~/dotfiles/" . 0))
|
||||
magit-popup-display-buffer-action nil ;; Not sure why this is here, wonder what it does
|
||||
magit-display-file-buffer-function #'switch-to-buffer-other-window
|
||||
magithub-clone-default-directory "~/src" ;; I want my stuff to clone to ~/projects
|
||||
magithub-preferred-remote-method 'ssh_url)) ;; HTTPS cloning is awful, i authenticate with ssh keys.
|
||||
@ -5,14 +5,11 @@
|
||||
;;; Code:
|
||||
(setq +todo-file "~/org/inbox.org")
|
||||
|
||||
(add-hook! :append org-load
|
||||
(after! org
|
||||
(setq org-directory (expand-file-name "~/org/")
|
||||
org-journal-dir "~/org/journal/"
|
||||
org-startup-indented t
|
||||
org-agenda-files (list org-directory)
|
||||
org-pretty-entities t
|
||||
org-hide-emphasis-markers t
|
||||
org-hide-leading-stars t
|
||||
org-contacts-files '("~/org/contacts.org")
|
||||
; attempt to return todo function to spacemacs
|
||||
evil-org-key-theme '(textobjects navigation additional insert todo)
|
||||
@ -21,9 +18,8 @@
|
||||
org-fontify-whole-heading-line t
|
||||
org-fontify-done-headline t
|
||||
org-fontify-quote-and-verse-blocks t
|
||||
org-log-done 'time
|
||||
org-bullets-face-name (quote org-bullet-face)
|
||||
org-bullets-bullet-list '("■" "◆" "▲" "▶")
|
||||
org-bullets-bullet-list '("#")
|
||||
|
||||
org-capture-templates
|
||||
'(
|
||||
("i" "Send to inbox" entry (file+headline "~/org/inbox.org" "Inbox")
|
||||
@ -35,7 +31,6 @@
|
||||
("n" "Add an idea" entry (file "~/org/ideas.org")
|
||||
"* %?\nEntered on %U\n"))
|
||||
|
||||
org-agenda-include-diary nil
|
||||
|
||||
org-todo-keywords
|
||||
'((sequence "TODO(t)" "NEXT(n)" "WAITING(w)" "MAYBE(m)" "|" "DONE(d)"))
|
||||
|
||||
@ -7,105 +7,167 @@
|
||||
|
||||
(add-to-list 'default-frame-alist '(inhibit-double-buffering . t))
|
||||
|
||||
(setq-default
|
||||
user-full-name "Colin Powell"
|
||||
user-mail-address "colin@onec.me"
|
||||
(setq user-full-name "Colin Powell"
|
||||
user-mail-address "colin@onec.me"
|
||||
|
||||
+workspaces-switch-project-function #'ignore
|
||||
+pretty-code-enabled-modes '(emacs-lisp-mode org-mode)
|
||||
+format-on-save-enabled-modes '(not emacs-lisp-mode)
|
||||
)
|
||||
doom-theme 'nimbus
|
||||
doom-font (font-spec :family "Iosevka" :size 16)
|
||||
doom-big-font (font-spec :family "Iosevka" :size 22))
|
||||
|
||||
;; (setq-hook! 'minibuffer-setup-hook show-trailing-whitespace nil)
|
||||
(setq ns-use-thin-smoothing t)
|
||||
(add-to-list 'default-frame-alist '(ns-transparent-titlebar . t))
|
||||
(add-to-list 'default-frame-alist '(ns-appearance . dark))
|
||||
;(add-hook 'window-setup-hook 'toggle-frame-maximized)
|
||||
;;
|
||||
;; Host-specific config
|
||||
|
||||
;; Keybindings
|
||||
(pcase (system-name)
|
||||
("halimede"
|
||||
(font-put doom-font :size 9)) ; smaller display
|
||||
("triton"
|
||||
;; I've swapped these keys on my keyboard
|
||||
(setq x-super-keysym 'meta
|
||||
x-meta-keysym 'super)))
|
||||
|
||||
(map!
|
||||
;; Easier window navigation
|
||||
:n "C-h" #'evil-window-left
|
||||
:n "C-j" #'evil-window-down
|
||||
:n "C-k" #'evil-window-up
|
||||
:n "C-l" #'evil-window-right
|
||||
|
||||
(:after treemacs-evil
|
||||
(:map evil-treemacs-state-map
|
||||
"C-h" #'evil-window-left
|
||||
"C-l" #'evil-window-right))
|
||||
|
||||
;; some handy alt shortcuts
|
||||
:n "s-g" #'magit-status
|
||||
:n "s-c" #'org-capture
|
||||
;; Let's be like our friends Slack and Discord
|
||||
:n "s-p" #'+ivy/project-search
|
||||
:n "s-k" #'counsel-recentf
|
||||
|
||||
;; Leader tricks
|
||||
(:leader
|
||||
(:prefix "f"
|
||||
:desc "Find file in dotfiles" :n "t" #'+hlissner/find-in-dotfiles
|
||||
:desc "Browse dotfiles" :n "T" #'+hlissner/browse-dotfiles)
|
||||
(:prefix "t"
|
||||
:desc "Toggle visual line mode" :n "v" #'visual-line-mode
|
||||
:desc "Toggle auto fill mode" :n "a" #'auto-fill-mode
|
||||
:desc "Switch themes" :n "t" #'counsel-load-theme)
|
||||
(:prefix "o"
|
||||
:desc "Elfeed feed reader" :n "f" #'elfeed)
|
||||
(:prefix "p"
|
||||
:desc "Black buffer" :n "b" #'blacken-buffer)
|
||||
(:prefix "y"
|
||||
:desc "Yank pop!" :n "p" #'counsel-yank-pop
|
||||
:desc "Git yank link" :n "g" #'git-link)
|
||||
(:prefix "n"
|
||||
:desc "Browse mode notes" :n "m" #'+hlissner/find-notes-for-major-mode
|
||||
:desc "Browse project notes" :n "p" #'+hlissner/find-notes-for-project)))
|
||||
(when IS-LINUX
|
||||
(font-put doom-font :weight 'semi-light))
|
||||
(when IS-MAC
|
||||
(setq ns-use-thin-smoothing t))
|
||||
|
||||
|
||||
;; Company mode
|
||||
(require 'company)
|
||||
(setq company-idle-delay 0.2
|
||||
completion-ignore-case t
|
||||
company-minimum-prefix-length 3
|
||||
company-async-timeout 2)
|
||||
;;(set! :company-backend 'python-mode '(company-anaconda))
|
||||
(add-hook 'prog-mode-hook 'global-company-mode)
|
||||
;;
|
||||
;; Keybinds
|
||||
|
||||
;; importmagic
|
||||
(add-hook 'python-mode-hook 'importmagic-mode)
|
||||
(map! :m "M-j" '+hlissner:multi-next-line
|
||||
:m "M-k" '+hlissner:multi-previous-line
|
||||
|
||||
;; Golang
|
||||
(add-hook 'go-mode-hook 'gofmt-before-save)
|
||||
;; Easier window movement
|
||||
:n "C-h" 'evil-window-left
|
||||
:n "C-j" 'evil-window-down
|
||||
:n "C-k" 'evil-window-up
|
||||
:n "C-l" 'evil-window-right
|
||||
|
||||
(:map evil-treemacs-state-map
|
||||
"C-h" 'evil-window-left
|
||||
"C-l" 'evil-window-right)
|
||||
|
||||
(:when IS-LINUX
|
||||
"s-x" #'execute-extended-command
|
||||
"s-;" #'eval-expression
|
||||
;; use super for window/frame navigation/manipulation
|
||||
"s-w" #'delete-window
|
||||
"s-W" #'delete-frame
|
||||
"s-n" #'+default/new-buffer
|
||||
"s-N" #'make-frame
|
||||
"s-q" (if (daemonp) #'delete-frame #'evil-quit-all)
|
||||
;; Restore OS undo, save, copy, & paste keys (without cua-mode, because
|
||||
;; it imposes some other functionality and overhead we don't need)
|
||||
"s-z" #'undo
|
||||
"s-c" (if (featurep 'evil) #'evil-yank #'copy-region-as-kill)
|
||||
"s-v" #'yank
|
||||
"s-s" #'save-buffer
|
||||
;; Buffer-local font scaling
|
||||
"s-+" (λ! (text-scale-set 0))
|
||||
"s-=" #'text-scale-increase
|
||||
"s--" #'text-scale-decrease
|
||||
;; Conventional text-editing keys
|
||||
"s-a" #'mark-whole-buffer
|
||||
:gi [s-return] #'+default/newline-below
|
||||
:gi [s-S-return] #'+default/newline-above
|
||||
:gi [s-backspace] #'doom/backward-kill-to-bol-and-indent)
|
||||
|
||||
:leader
|
||||
(:prefix "f"
|
||||
:desc "Find file in dotfiles" "t" #'+hlissner/find-in-dotfiles
|
||||
:desc "Browse dotfiles" "T" #'+hlissner/browse-dotfiles)
|
||||
(:prefix "t"
|
||||
:desc "Toggle visual line mode" "v" #'visual-line-mode
|
||||
:desc "Toggle auto fill mode" "a" #'auto-fill-mode
|
||||
:desc "Switch themes" "t" #'counsel-load-theme)
|
||||
(:prefix "o"
|
||||
:desc "Elfeed feed reader" "f" #'elfeed)
|
||||
(:prefix "p"
|
||||
:desc "Black buffer" "b" #'blacken-buffer)
|
||||
(:prefix "y"
|
||||
:desc "Yank pop!" "p" #'counsel-yank-pop
|
||||
:desc "Git yank link" "g" #'git-link))
|
||||
|
||||
;; app/rss
|
||||
(add-hook! 'elfeed-show-mode-hook (text-scale-set 1.5))
|
||||
|
||||
;;
|
||||
;; Modules
|
||||
|
||||
(setq +workspaces-switch-project-function #'ignore
|
||||
+format-on-save-enabled-modes '(python-mode)
|
||||
+pretty-code-enabled-modes '(emacs-lisp-mode org-mode))
|
||||
|
||||
;; app/rss
|
||||
(add-hook! 'elfeed-show-mode-hook (text-scale-set 2))
|
||||
|
||||
;; emacs/eshell
|
||||
(after! eshell
|
||||
(set-eshell-alias!
|
||||
"f" "find-file $1"
|
||||
"f" "(other-window 1) && find-file $1"
|
||||
"l" "ls -lh"
|
||||
"d" "dired $1"
|
||||
"dc" "docker-compose $1"
|
||||
"gl" "(call-interactively 'magit-log-current)"
|
||||
"gs" "magit-status"
|
||||
"gc" "magit-commit"
|
||||
"rg" "rg --color=always $*"))
|
||||
|
||||
;; Add notice for lines over 88 chars
|
||||
;;(setq-default
|
||||
;; whitespace-line-column 88
|
||||
;; whitespace-style '(face lines-tail))
|
||||
"gc" "magit-commit"))
|
||||
|
||||
;; tools/magit
|
||||
(setq magit-repository-directories '(("~/devel" . 2))
|
||||
magit-save-repository-buffers nil)
|
||||
(setq magit-repository-directories '(("~/work" . 2))
|
||||
magit-save-repository-buffers nil
|
||||
transient-values '((magit-commit "--gpg-sign=5F6C0EA160557395")
|
||||
(magit-rebase "--autosquash" "--gpg-sign=5F6C0EA160557395")
|
||||
(magit-pull "--rebase" "--gpg-sign=5F6C0EA160557395")))
|
||||
|
||||
;; lang/org
|
||||
(setq org-directory (expand-file-name "~/org/")
|
||||
org-journal-dir "~/org/journal/")
|
||||
;; Some appearance things
|
||||
(setq org-agenda-block-separator ""
|
||||
org-fontify-whole-heading-line t
|
||||
org-fontify-done-headline t
|
||||
org-fontify-quote-and-verse-blocks t
|
||||
org-pretty-entities t
|
||||
org-ellipsis " ▼ "
|
||||
|
||||
;; make the lines in the buffer wrap around the edges of the screen.
|
||||
;(add-hook 'org-mode-hook '(lambda () (visual-line-mode)))
|
||||
;; The standard unicode characters are usually misaligned depending on the
|
||||
;; font. This bugs me. Markdown #-marks for headlines are more elegant.
|
||||
org-bullets-bullet-list '("#"))
|
||||
|
||||
(after! org
|
||||
(setq org-capture-templates '(("i" "Send to inbox" entry (file+headline "~/org/inbox.org" "Inbox") "* TODO %?\n")
|
||||
("w" "Work diary entry" entry (file "~/org/work_diary.org")
|
||||
"* %u\n%?\n"))
|
||||
org-use-tag-inheritance nil
|
||||
org-tags-exclude-from-inheritance '("PROJECT" "SPRINT")
|
||||
;org-stuck-projects '("+PROJECT/-MAYBE-DONE" ("TODO" "NEXT") nil "\\<IGNORE\\>")
|
||||
;org-tag-alist '(("PROJECT" . ?p) ("@home" . ?h) ("@night" . ?n) ("@selectp" . ?s)
|
||||
; ("@errand" . ?e) ("@read" . ?r) ("@work" . ?w) ("@family" . ?f))
|
||||
;org-modules '(org-drill org-clock org-id org-info org-habit org-protocol org-annotate-file
|
||||
; org-eval org-expiry org-contacts org-man org-notmuch org-collector org-panel
|
||||
; org-screen org-toc)
|
||||
|
||||
org-refile-targets '(("~/org/todo.org" :maxlevel . 2)
|
||||
("~/org/someday.org" :maxlevel . 2)
|
||||
("~/org/town.org" :maxlevel . 2)
|
||||
("~/org/personal.org" :maxlevel . 2)
|
||||
("~/org/elation.org" :maxlevel . 2))
|
||||
)
|
||||
|
||||
(setq org-todo-keywords '((sequence "TODO(t)" "NEXT(n)" "WAITING(w)" "MAYBE(m)" "|" "DONE(d)"))))
|
||||
|
||||
;; Org specific keybindings
|
||||
(map! :leader
|
||||
(:prefix "a"
|
||||
:desc "Org Agenda" "o" #'org-agenda
|
||||
:desc "Org open link" "l" #'org-open-at-point
|
||||
:desc "Sync gcal with org" "g" #'org-gcal-sync
|
||||
:desc "Set task deadline" "d" #'org-deadline
|
||||
:desc "Schedule task" "s" #'org-schedule
|
||||
:desc "New journal entry" "j" #'org-journal-new-entry
|
||||
:desc "Org set property" "p" #'org-set-progerty
|
||||
:desc "Save all org buffers" "a" #'org-save-all-org-buffers
|
||||
:desc "Org todo" "t" #'org-todo
|
||||
:desc "Org set tags" "T" #'org-set-tags-command))
|
||||
|
||||
;;; Setup sending email with msmtp
|
||||
(setq send-mail-function 'sendmail-send-it
|
||||
@ -113,19 +175,3 @@
|
||||
mail-specify-envelope-from t
|
||||
message-sendmail-envelope-from 'header
|
||||
mail-envelope-from 'header)
|
||||
|
||||
;; enable ivy buffer icons
|
||||
(setq ivy-buffer-icons t)
|
||||
|
||||
;; Hide hidden files in treemacs
|
||||
(setq treemacs-show-hidden-files nil)
|
||||
|
||||
;;(load! "+org-daypage") ;; hardwire this baby in here somewhere
|
||||
(load! "+ui") ;; My ui mods. Also contains ligature stuff.
|
||||
(load! "+music") ;; Music stuff, visible through SPC-a-m. Not perfect.
|
||||
(load! "+ranger") ;; File manager stuff
|
||||
;;(load! "+reason") ;; ReasonML stuff
|
||||
(load! "+mail") ;; Mail stuff
|
||||
(load! "+org") ;; Org mode stuff like todos and rebindings
|
||||
(load! "+org-gcal") ;; Org mode stuff like todos and rebindings
|
||||
(load! "+wttrin") ;; Weather config
|
||||
|
||||
@ -6,16 +6,15 @@
|
||||
eval ; run code, run (also, repls)
|
||||
(evil +everywhere); come to the dark side, we have cookies
|
||||
file-templates ; auto-snippets for empty files
|
||||
(lookup ; helps you navigate your code and documentation
|
||||
+docsets) ; ...or in Dash docsets locally
|
||||
(lookup +docsets)
|
||||
snippets ; my elves. They type so I don't have to
|
||||
workspaces ; tab emulation, persistence & separate workspaces
|
||||
|
||||
:completion
|
||||
(ivy +fuzzy) ; a search engine for love and life
|
||||
company ; the ultimate code completion backend
|
||||
;;(helm +fuzzy)
|
||||
;;ido ; the other *other* search engine...
|
||||
(ivy +fuzzy) ; a search engine for love and life
|
||||
|
||||
:ui
|
||||
;;deft ; notational velocity for Emacs
|
||||
@ -29,12 +28,10 @@
|
||||
nav-flash ; blink the current line after jumping
|
||||
;;neotree ; a project drawer, like NERDTree for vim
|
||||
treemacs ; a project drawer, like neotree but cooler
|
||||
(popup ; tame sudden yet inevitable temporary windows
|
||||
+all ; catch all popups that start with an asterix
|
||||
+defaults) ; default popup rules
|
||||
;;pretty-code ; replace bits of code with pretty symbols
|
||||
(popup +all +defaults)
|
||||
pretty-code ; replace bits of code with pretty symbols
|
||||
;;tabbar ; FIXME an (incomplete) tab bar for Emacs
|
||||
;;unicode ; extended unicode support for various languages
|
||||
unicode ; extended unicode support for various languages
|
||||
vc-gutter ; vcs diff in the fringe
|
||||
vi-tilde-fringe ; fringe tildes to mark beyond EOB
|
||||
window-select ; visually switch windows
|
||||
@ -48,10 +45,7 @@
|
||||
rotate-text ; cycle region at point between text candidates
|
||||
|
||||
:emacs
|
||||
(dired ; making dired pretty [functional]
|
||||
;;+ranger ; bringing the goodness of ranger to dired
|
||||
+icons ; colorful icons for dired-mode
|
||||
)
|
||||
(dired +ranger)
|
||||
electric ; smarter, keyword-based electric-indent
|
||||
eshell ; a consistent, cross-platform shell (WIP)
|
||||
imenu ; an imenu sidebar and searchable code index
|
||||
@ -87,13 +81,13 @@
|
||||
;;coq ; proofs-as-programs
|
||||
;;crystal ; ruby at the speed of c
|
||||
;;csharp ; unity, .NET, and mono shenanigans
|
||||
data ; config/data formats
|
||||
data ; config/data formats
|
||||
;;erlang ; an elegant language for a more civilized age
|
||||
elixir ; erlang done right
|
||||
elixir ; erlang done right
|
||||
;;elm ; care for a cup of TEA?
|
||||
emacs-lisp ; drown in parentheses
|
||||
emacs-lisp ; drown in parentheses
|
||||
;;ess ; emacs speaks statistics
|
||||
go ; the hipster dialect
|
||||
(go +lsp) ; the hipster dialect
|
||||
;;(haskell +intero) ; a language that's lazier than I am
|
||||
;;hy ; readability of scheme w/ speed of python
|
||||
;;idris ;
|
||||
@ -107,14 +101,7 @@
|
||||
;;nim ; python + lisp at the speed of c
|
||||
;;nix ; I hereby declare "nix geht mehr!"
|
||||
;;ocaml ; an objective camel
|
||||
(org ; organize your plain life in plain text
|
||||
+attach ; custom attachment system
|
||||
+babel ; running code in org
|
||||
+capture ; org-capture in and outside of Emacs
|
||||
+export ; Exporting org to whatever you want
|
||||
+hugo
|
||||
+journal
|
||||
+present) ; Emacs for presentations
|
||||
(org +attach +babel +capture +export +present)
|
||||
;;perl ; write code no one else can comprehend
|
||||
;;php ; perl's insecure younger brother
|
||||
;;plantuml ; diagrams for confusing people more
|
||||
@ -136,9 +123,9 @@
|
||||
;; toward a specific purpose. They may have additional dependencies and
|
||||
;; should be loaded late.
|
||||
:app
|
||||
notmuch
|
||||
;;(email +gmail) ; emacs as an email client
|
||||
irc ; how neckbeards socialize
|
||||
notmuch
|
||||
(rss +org) ; emacs as an RSS reader
|
||||
;;twitter ; twitter client https://twitter.com/vnought
|
||||
;(write ; emacs as a word processor (latex + org + markdown)
|
||||
|
||||
Reference in New Issue
Block a user