Emacs notes (doom emacs)
Org
handy cheatsheet: https://orgmode.org/orgcard.pdf
To get a TODO item created on the same level as the one in which you’re working (
org-insert-todo-heading)Add tag: To add a tag to a heading (* line)
SPC m q(orC-c C-q) then type the tag name, should appear in grayTag search: To search all the tags:
SPC o a mSchedule/Deadline: To set something as scheduled in org-agenda (so it shows up when you
SPC o A n)SPC m d s, similarly for setting a deadline for somethingSPC m d dSort TODOs: to sort TODOs (in various ways) go to the heading and select
org-sort-entries. Capitalization of an option will reverse the sort order.Insert a code block
<sfollowed immediately byTab
Magit
Committing
Specific lines in a changed file
Say you’ve edited some file (README.md) with the following lines:
| |
and you want to only commit one line (line 1, in this example):
| |
you’ll then get a magit window, look into the Unstaged changes line
(open with Tab). You should then see some git output with the delta:
| |
To select only the commit this line, you would highlight the line as a
visual section (in Vim lingo) and stage it with s. Then commit the
newly-staged section with
| |
Now you can push to a repository with magit-push
You can visual-select any number of lines, hit s, select a totally
different line, hit s (again) and then commit to be ultra-selective
with your staging.