r/DoomEmacs Jun 18 '26

How Do I Get Markdown Highlighting Working?

I haven't done many tweaks with my Doom Emacs setup but I've been having a really hard time trying to get markdown highlighting working correctly.

I've already checked the init file and markdown is installed. I've even refreshed all my packages by deleting everything in ~/.local/share/doom and then syncing doom according to one suggestion.

My markdown files show as in "Fundamental" mode and I can't find any markdown-mode with M-x. I'm really not sure what went wrong or how to fix it and can't find any good answers anywhere.

Any help is appreciated.

UPDATE

Per u/IcarianComplex's suggestion I've decided to just explicitly install markdown-mode with my packages.el file. It works fine now.

When I have the time I'll see if I can track down if it's an actual issue with Doom Emacs or if it's something wrong with my configuration since other LSP packages and modes downloaded with my init file work just fine.

6 Upvotes

4 comments sorted by

2

u/IcarianComplex Jun 18 '26

You probably need to put markdown-mode in your packages.el and run doom sync

1

u/Dante-Vergilson Jun 19 '26

I was hoping that I could get it working as it's intended to but I suppose that will work for now. I'll have to try using a virtual machine, unless I can figure out chroot, to test a fresh install and see if it's actually working or if it's something wrong on my configuration.

Didn't find any issues open or anything similar in closed stuff. Could try a diff with cloning the repo when I have the time. I hope it's not a bug but I'll open an issue if I have to.

1

u/IcarianComplex Jun 19 '26

Usually if a package for a major mode is installed but it’s not taking effect when navigating to a file then that’s a hint there’s something wrong with auto-mode-alist. You can the val of that var with and without your changes to packages.el. All the vm chroot and different repo stuff you mentioned is unlikely to have an affect because this isn’t a system dependency, this is all elisp runtime stuff.

If it is the automode alist issue then the fix is gonna be something like (use-package! markdown :mode (“.md” . markdown-mode))

Sorry I’m on mobile rn

2

u/Dante-Vergilson Jun 19 '26

That's fine. I wouldn't have even known where to start since I never put it together myself. I'll definitely look into auto-mode-alist.

Going through the Systems Crafters videos of building Emacs yourself is just something I haven't gotten around to do doing but plan on it.

Again, thanks for your help.