/r/DoomEmacs
A Reddit for Doom Emacs: a configuration framework for GNU Emacs.
This community is for discussing features, issues, questions, and more related to the Doom flavor of Emacs
/r/DoomEmacs
This is most likely a very simple question, however I am unable to find the answer on my own, and would appreciate some help. In doom/init.el I have for instance uncommitted python from the list, which highlights the syntax correctly in python files. However even after I have uncommented rust and gdscript (and doing doom/reload) files using those languages still appear without any highlighting. I don't really see what I am doing wrong here, as some other languages other than python were also able to work correctly from me simply uncommenting them from the init.el file. Do I have to do something extra to make rust and gdscript work?
I don't know if this is relevant at all, but figured I should mention it just in case: I tried both just having "gdscript" and "(gdscript +lsp)" in the init file, however neither worked.
Any way to enable more options when trying to close the buffer without having to rewrite the code somewhere else ? https://in.comum.org/smart-way-to-close-files.html
Thanks
TAB and S-TAB trigger org-cycle
in org-mode.
I find it very annoying in insert state, since it is quite a workflow interruption when you hit it by mistake, and, to me, a main point of modal editing is to focus on editing while in insert state.
Anyway, I have been using Doom for a bit under a year, and, except some very specific modes like org-agenda or gptel among others, I have been able to modify Doom bindings with 'relative' ease, but I cannot remove this one. Even worse, I got some unexpected behavior with the code I added:
Now, when I press TAB in insert mode at the begining of a line, it runs what I believe is the tab-to-tab-stop
command, and when in the middle of a word/sentence, it indents the parent header. I have no sign of those changes with describe-key
, it actually looks like the modifications are working...
This is what I settled for after many attempts/variations:
```
(map! :after (evil org)
:map org-mode-map
:i "TAB" nil
:i "<tab>" nil
;; :i "<tab>" #'tab-to-tab-stop
:map evil-org-mode-map
:i "<tab>" nil
:i "TAB" nil)
```
Any help would be appreciated, thanks for your time.
I am trying to use non doom themes, but any theme I install and try has the same problem:
The org list markers (`-`, `+`, `1.`, `a.`) are invisible when I load any of them.
Those markers show the following faces whether I am using a Doom theme or not:
face (org-list-dt org-indent)
`org-indent` is supposed to hide characters and as far as I understand is meant for the org headers leading stars. However, when loading a third party theme, `org-indent` takes over and makes org lists illegible.
When using a Doom theme, faces appear to be exactly the same, but `org-list-dt` is used to highlight the markers.
There must be a loading sequence issue because I found out that third party themes actually work as expected in the specific case where I run `doom/restart-and-reload` with an org file focused in the current window. In that case, it works but I cannot figure out why. I tried delaying the theme loading in many ways using varitions of `after!`, but nothing changes the outcome.
I am trying to use `ef-themes`, but I tried `modus-themes`, and half a dozen available themes in Melpa like `catpuccin` among others. I consistently get the same results.
I tested with a 'minimal' config file, only leaving my keybindings and user info, and I am completely running out of ideas. Knowing if anyone else is affected by this problem would be a great help.
Thanks for your time.
===== Workaround =====
I am sharing an acceptable workaround I finally settled for. It simply consists in overriding the `org-indent` face with `org-list-dt`. It is however a trade-off, and involves giving up on a few org 'prettification' options:
For me, it is not a big deal because I have been meaning to remove 'prettification' packages for a while now as it accounts for more than 50% of loading performance costs according to the Emacs profiling tool which is significant on big files like a literate config for example. Without `org-superstar` and indent, hiding leading stars does not make much sense to me. It does feel weird at first (but so does a new theme), but I have already gotten used to it.
Note that removing org-indent altogether works without additional config tweaks, but I cannot give up on org list indentation (use `org-mode-hook` to do so).
What I added to my config (I am sorry if I am not using code blocks, but I cannot get used to reddit editor, and it won't respect line breaks when I paste from Emacs):
```
(after! org
;; Should turn off outline contents indentation altogether
;; Does not seem to have any effect on Doom though...
;; (setq! org-indent-mode-turns-off-org-adapt-indentation t)
;; Set header sections indentation (0 to disable)
;; This removes outline placeholders used to indent headers
;; It looks weird when overriding org-indent face in Doom so
;; third party themes list markers remain visible.
(setq! org-indent-indentation-per-level 0)
;; Control org headers stars visibility
;; (Looks better turned off when outline indentation is disabled)
(setq! org-indent-mode-turns-on-hiding-stars nil)
(setq! org-hide-leading-stars nil)
)
```
When I click the Discord link, it asks me to verify an email address. Mine gets filled in automatically but then it says, I'm already registered with that email... I know that... I want to join the Discord. Maybe an invite link would be more appropriate?
I thought I would try out doom emacs instead of my plain vanilla configuration. I installed it in Mac OS ( with emacs-plus) , uncomment “common lisp” in the init.el and did a “doom sync” . Then when I run it and load a .lisp file , sly tries to connect and then numerous errors get printed and there is no connection to sly. Anyone have the same issue ? I’m not sure anyone is using the Common Lisp configuration so maybe I should abandon.
Hi Everyone, I am working on a React Typescript Project based on Vite and I was hopeful you could guide me what packages and configuration do I need as per my requirements:
=> Autocomplete for TSX files
=> Autocomplete for CSS modules
=> Recommended LSP to use for React
I have recently switched to nixos from popos. I had been using org mode to take notes and make Todos. how can I install doom emacs on nixos? I am using home-manager and have managed to install emacs but can't understand how to install doomemacs on it. Any help would be appreciated.
I just got an error out the blue:
```
Unexpected error in Doom's core: list/doom-keybinds.el, (error Eager macro-expansion failure: (file-missing "Cannot open load file" "No such file or directory" "pp"))
```
Any ideas on what went wrong, or what I need to do to remedy this?
I find that most Emacs books and guides online list shortcuts for vanilla Emacs. Do you have a goto website/guide/book, where shortcuts are Evil/DoomEmacs ? I noticed a lot of pages in the DoomEmacs manual are not written, either empty placeholders or links to no page.
Hi all.
I use web-mode
to edit Laravel blade templates (.blade.php
extension). I don't want to use LSP on these files so I added this snippet to my config.el
file to prevent LSP from starting when I edit them:
(pushnew! lsp-language-id-configuration '(web-mode . ""))
It worked fine until recently.
Now, whenever I open a file in web-mode
it asks me to install a language server. It says:
Unable to find installed server supporting this file. The following servers could be installed automatically:
and presents me with a list with only one choice: copilot-ls
.
How can I stop this and get the old behavior back?
I'm using Doom Emacs so not really sure if this is something specific for doom or lsp-mode
in general.
Thanks in advance.
Affe stopped working for me recently with it's latest update. There were changes made to accommodate the latest version of Consult which Doom isn't using yet. In the meantime, to get Affe working again, here's what fixed it for me:
In packages.el I had to pin the previous commit of affe like so:
(package! affe
:pin "a9ed240"
:recipe (:host github :repo "minad/affe"))
Hello Everyone! I keep trying to install doom emacs on arch linux and i get this output everytime
Installing Doom Emacs!
✓ Created ~/.config/doom/
- Creating ~/.config/doom/init.el...
✓ Done!
- Creating ~/.config/doom/config.el...
✓ Done!
- Creating ~/.config/doom/packages.el...
✓ Done!
Generate an envvar file? (see `doom help env` for details) (y or n) y
> Generating envvars file
✓ Generated ~/.config/emacs/.local/env
> Installing plugins
> Installing straight...
x The package manager threw an error
x Last 16 lines of straight's error log:
$ cd /home/zakky/.config/emacs/.local/straight/repos/melpa/
$ git submodule update --init --recursive
[Return code: 0]
$ cd /home/zakky/.config/emacs/.local/straight/repos/
$ git clone --origin origin --no-checkout https\://git.savannah.gnu.org/git/emacs/nongnu.git /home/zakky/.config/emacs/.local/straight/repos/nongnu-elpa/ --depth 1 --single-branch --no-tags
Cloning into '/home/zakky/.config/emacs/.local/straight/repos/nongnu-elpa'...
fatal: unable to access 'https://git.savannah.gnu.org/git/emacs/nongnu.git/': Empty reply from server
[Return code: 128]
$ cd /home/zakky/.config/emacs/.local/straight/repos/
$ git clone --origin origin --no-checkout https\://git.savannah.gnu.org/git/emacs/nongnu.git /home/zakky/.config/emacs/.local/straight/repos/nongnu-elpa/ --no-single-branch
Cloning into '/home/zakky/.config/emacs/.local/straight/repos/nongnu-elpa'...
fatal: unable to access 'https://git.savannah.gnu.org/git/emacs/nongnu.git/': Empty reply from server
[Return code: 128]
$ cd /home/zakky/.config/emacs/.local/straight/repos/nongnu-elpa/
$ git branch -r
[File error while Setting current directory]
Opening output file: No such file or directory, /home/zakky/.config/emacs/.local/state/logs/cli.doom.250117191351.25260.error
Can anyone help me setup org roam and dooms emac it js very difficult and complex and help from any one would be highly appreciated……
Hi there. Im Ardie. Ive been using Emacs for several. I started with Spacemacs many years ago. Im currently trying to install Doom Emacs on a remote machine, as I plan on "research" and write about it. Mostly becoz due to the nature of my work, which is mostly people with non-programming working in GIS. And the only software they use is Emacs, albeit very VERY vanilla. I plan to present about Doom Emacs.
Anyway, cut to the chase, I cant seem to install properly Doom Emacs. As it keeps installing in the wrong "home" folder. Im using non-admin remote Windows machine, it insists the existence of .doom.d, even when I removed, and no matter how many times I reinstall it.
- Skipping ~/.doom.d/ (already exists)....
- Skipping ~/.doom.d/init.el (already exists)...
All the other path variables are set properly (emacs.exe, fd.exe...). Is there any way to specify to Doom Emacs to install .doom.d at a specific location
(Im using Emacs 28, I can switch to 29 no problem, if that solves the issue)
Hi Folks
Even after some years of use with Doom/Vim-bindings setup, my muscle memory from classic emacs for C-e for end-of-line is still bothering me.
It works as I expect in insert mode. In normal/command mode, it doesn't. It scrolls the buffer by one line which is a useless function for me.
How would I go about changing this? I have done some simple key-binding changes in the past. But this sounds like it may go deeper into multiple keymaps?
Advise welcome.
(I tried to create a login in the newly announced discourse. But it failed for some reason..)
EDIT: Ha, the Discourse announcement wasn't new. I just noticed it !
I just tried to reinstall doom, and then I got this error message.
Yesterday the installation was just fine, but I needed to reinstall it bc of a little mistake I made. Suddenly it does not work anymore and doom wont open up. when I open emacs, only the GNU emacs appears.
fatal: unable to access 'https://git.savannah.gnu.org/git/emacs/nongnu.git/': The requested URL returned error: 502
[Return code: 128]
At this point I don't know how to move on. Does somebody of you know a solution maybe ?
Running it on a Mac OS M1 Pro
This might be a very newbie question: I'm still getting used to Doom Emacs!
I was updating my emacs when I got this response for gptel, along with another package. (Wallabag)
Repository "gptel" has a dirty worktree
M test
1) Abort
2) Stash changes
3) Discard changes (Choose this if unsure)
I chose (3) and continued along. Just for peace of mind, I did the update again. The other package didn't provide this same response, but gptel did, and continues to, every time I run 'doom upgrade.'
Dumb question: does this mean that I have gptel installed? Is this built in to Doom Emacs?
I haven't installed or utilized gptel or any LLM tech in any way, so I'm not sure what I could have done on my end to change anything.
I'm a total Emacs beginner and essentially a non-programmer. I recently installed Doom Emacs on my Macbook (using emacs-mac on MacOS Monterey, x86 architecture, Emacs 29.1) and am finding that it will lock up randomly with the spinning ball cursor for no discernible reason; sometimes a few seconds or minutes after opening, sometimes a half hour later.
I haven't installed any plugins aside from the Doom defaults, and Doom Doctor only gives me two warnings that don't seem important (one about my grep install not having PCRE lookaheads support and one about emacs not working with Keychain). The crashes don't seem to be caused by any specific keybind as they occur during basic text editing and even just on the splash screen.
Pressing C-g repeatedly doesn't do anything and I end up needing to force close the application. I'm not really sure how to go about debugging this and I can't find too much info on how to debug Emacs in general: Most freezes seem to be the result of faulty elisp plugins, but I'm just running the Doom defaults. Some people say to use the gdb debugger which I've installed but I honestly have no idea how to go about getting Emacs to run with it, let alone use it to actually debug anything.
Does anyone have any advice on how to resolve this issue? I'm unsure if it's an Emacs problem or a Doom problem, though I've seen a few issue threads that make it seem like it may just be a problem with MacOS Emacs in general.
SOLVED: doom sync --rebuild
I have this problem with Python files.
Note that deleting the bottom lines (for pyright LSP) doesn't matter (after doom sync
). The same error.
Is this a bug to be reported?
I am new to emacs(doom emacs),I’m currently using Emacs 29.4 on Fedora, and I’m seeing this warning when running ./doom doctor
> Checking your Emacs version...
! Detected emacs-pgtk 29.4!
If you are experiencing segfaults (crashes), consider downgrading to
29.3 or upgrading to 30+. A known bug in 29.4 causes intermittent crashes. See doomemacs#7915 for details.
This warning suggests that the current version of Emacs is prone to crashes, and I’m wondering whether it would be better to build Emacs from source (possibly downgrading to 29.3 or upgrading to a 30+ version) or just use the system package manager (dnf in my case) to handle the installation and updates. Or should I just simply ignore the warning
Source to build from : https://github.com/emacs-mirror/emacs
Hi, I am trying to set the variable evil-shift-width to 4 as- (setq evil-shift-width 4)
. However, this does not make the change to that variable permanent. I have also tried using setq-default
. That is not working as well.
Next, I tried this-
(after! org
(add-hook 'org-mode-hook
(function (lambda ()
(setq-default evil-shift-width 4)))))
This is not working as well and does not work after I restart emacs.
I want to enable syntax highlighting for shell script code blocks in org file. However, there is no syntax highlighting even after enabling tree-sitter. However, there is syntax highlighting for shell script (.sh) files.
org-src-lang-modes has the sh variable set.
Also, src blocks shows syntax highlighting for other languages which I use.
Image link.
I rely a lot on auto-complete/intellisense when coding. I have tried using pyright but I am having some problems with it. I want the auto-complete window to appear as quick as possible, however it takes 0.5 seconds of idling before it actually pops up. Since I rely on it so frequently that time does add up pretty quickly. I'm very new to Doom Emacs, so I don't really know how everything works yet, but I'm pretty sure that I remember changing some setting for how long the pyright window takes to pop up? I have tried looking around but I have absolutely no idea where I changed that setting. I'm not even sure if it actually works like this or if I am just misremembering.
I'm also wondering if there exists any alternatives to pyright, for if I were to code in another language, like for example Rust. Are there individual packages for each language, or are universal packages that work for every (or at last a lot of) languages a thing?
Thanks in advance!
Hi!
I have function in config.el (which works if i execute it with C-x-e), but i would like to run it with SPC-1 (press and release space, then press 1). My decision is not working obv
(defun
hmmb
()
(if (equal 1 max-mini-window-height)
(setq max-mini-window-height nil)
(setq max-mini-window-height 1)
)
)
(map! :leader
"1" #'hmmb)
I haven’t found much utility in writing Elisp to do things besides very small functions a matter of 5-10 lines, and configuration of eMacs, just given how much effort it is relative to return, but I may just lack imagination or skill.
Do you find yourself writing substantial Elisp?
Every once in a while, a doom upgrade
causes something in my config to break, and often that's due to an old/deprecated package being replaced with a different one. In recent memory, company
being replaced with corfu
, highlight-indent-guides
being replaced with indent-bars
, and I'm currently searching for whatever has replaced drag-stuff
.
It's not the end of the world, but each time this happens it usually takes me a little while to track down the culprit, and I thought there must surely be a changelog somewhere that I can search for the package name to see what the replacement is, but I haven't been able to find it so far!
Does something like that exist? How do folks here usually go about tracking down replacements for missing/broken packages?
I am totally new to Emacs and I want to learn. I have installed doom Emacs on arch wsl2. I've installed all-the-icons and nerd-fonts, but none of them solved the problem. Can someone help?
Hi! I've been using doom emacs for a few years now but never really git to customising more than a couple of already packaged information.
I'm trying to setup equake following the project's readme but I'm having trouble with it.
My two problems :
Could someone give me pointers ?
Whenever I start emacs and see my org agenda, and press RET on a task to open it, the cursor is at the top of the file, which had the task. If I kill this file buffer and again select the task from the org agenda, the cursor still moves to the start of the file. However, if I don't kill the file buffer, and then open the task, the cursor is at the appropriate location of the file.
How can I solve this?
As a side note, my (only) agenda file has a lot of formatting errors; task body being displayed after org-ellipses for some headings. I think it started after I started refiling tasks to my agenda file.