Cheatography
https://cheatography.com
The Ultimate Doom Emacs Cheat Sheet from https://github.com/niyumard/Doom-Emacs-Cheat-Sheet
Command Abbreviations
C |
“Control” key |
M |
“Alt” or “Option” key |
S |
“Super” or “Command” key |
SPC |
“Space” key |
Buffers
SPC b b |
Open another buffer workspace buffer |
SPC b B |
List all the buffer |
SPC , |
Switch buffers (its an alias) |
SPC SHIFT |
Switch to all buffers |
SPC b X |
Create a scratch buffer |
SPC b s |
Save and name a buffer |
Buffers are a special concept in emacs they can be terminals, files, directories, etc
Workspaces
SPC TAB n |
New workspace |
SPC TAB N |
Newly named workspace |
SPC TAB [ |
Previous workspace |
SPC TAB ] |
Next workspace |
SPC TAB d |
Remove workspace |
SPC TAB R |
Restore last session |
M-1 |
Switch to workspace 1 |
M-2 |
Switch to workspace 2 and so forth |
Projects with Projectile
SPC p p |
Open a project |
SPC SPC |
Open a file in a project |
SPC o p |
Open the file explorer |
SPC o E |
Open the shell (eshell) in fullscreen |
SPC o e |
Open the shell (eshell) in a popup window |
SPC f r |
Recently visited files |
SPC p r |
Recently visited files in a project |
M-x projectile-discover-projects-in-directory |
Find projects within given folder using Projectile |
M-x projectile-discover-projects-in-search-path |
Find projects in the folder defined by the projectile-project-search-path variable using Projectile |
|
|
General
SPC f s |
Save the current file |
SPC : |
Enter a command |
SPC q q |
Close Emacs |
SPC f D |
Delete this file |
Windows
SPC w v |
Window split vertically |
SPC w s |
Window split horizonally |
SPC w w |
Switch windows |
SPC w q |
Close window, frame, quit EMACS if last frame |
SPC w + and SPC w - |
Increase and decrease window height |
SPC w > and SPC w < |
Increase and decrease window width |
You can use vim motion keys to navigate between open windows for example SPC w H moves the window to the left.
Windows are panes in your screen
Magit
SPC g g |
Shows Magit status page. Most commands are done from the status page. Use tab to expand headlines in the status page. |
? |
in Magit’s status page for a nice list of available commands and help, q to close this help page |
TAB |
Open diff view for a file |
s |
Press s under “Unstaged changes” to stage a change |
u |
Undo a change |
c |
Commit |
b s |
Branch and spinoff to create another branch, rewinding the commits you made to master |
b b |
Switch branches |
t t |
Create a tag, default place is the commit you are currently selecting |
V |
Select a change in a diff and x to discard that change. |
s |
Stage |
c |
Commit, you can q to quit the commit screen |
P |
push and then p to your remote or u to a another remote |
File Tree
SPC o p |
Open neotree or treemacs |
Set up neotree or treemacs in your init.el file
Terminal
SPC o T |
Open vterm |
SPC o t |
Open vterm in a popup window |
Set up vterm in your init.el file.
|
|
Dired
C-x d |
Open dired |
RET |
Go to a folder or open a file |
- |
Go one folder back |
+ |
Create a new directory |
d |
Mark the files for deletion, press x to delete. |
M |
Change permissions |
o |
Sort by modes |
O |
Change the owner |
m |
Mark and u to unmark files or directories |
u |
Unselect all |
t |
Invert the selection |
t |
Switch between files and directories |
C |
Copy |
R |
Move |
h, j, k, l |
Move the cusor |
( |
Toggle a simple view |
SPC . |
Create or find a file |
* |
Select all directories |
C |
Copy to another window |
R |
Move to another window |
dired-do-what-i-mean-target |
Set to true |
i |
Edit file/dir name |
Dired (Directory Editor) is how you interfaces with a directory
Org Mode
* |
* for a h1 ** for an h2 and so on |
TAB |
Fold a subtree (hide it) on a section |
SHIFT TAB |
Cycle through folded states |
CTRL return |
Create a headline of the same type |
M-arrow up |
Shift the position of the section |
M-h |
Promotes a headline to the next level |
M-l |
Demotes |
SPC m l |
Add a link to an org page |
:: |
Specify a heading or a line number |
SPC n l |
Stores a link to a particular headline |
SPC i s |
Insert code snippets |
C-c C-c |
Execute the code |
SPC m ‘ |
Edit inside the babel in another buffer |
TODO |
Create a task by prefixing any heading with TODO |
DONE |
Means the task is done |
SPC m t |
Change a status of a todo |
SHIFT left and SHIFT right |
Change the status of a todo as well |
SPC o a t |
Open the agenda -> todo list |
q |
Quit |
SHIFT up and SHIFT down |
Toggle the priority of tasks |
org-fancy-priorities |
Gives you fancy looking priorities |
SPC m q |
Tag a headline |
SPC m o |
Set a property |
SHIFT right and SHIFT left |
Change the type of lists |
[ ] |
This is still todo |
[-] |
This is in progress |
[X] |
This is a done task |
|
Created By
Metadata
Comments
No comments yet. Add yours below!
Add a Comment
Related Cheat Sheets