Back to News
Advertisement
Advertisement

⚡ Community Insights

Discussion Sentiment

79% Positive

Analyzed from 1272 words in the discussion.

Trending Topics

#mode#markdown#emacs#org#code#https#agent#com#using#shell

Discussion (63 Comments)Read Original on HackerNews

RahulMJabout 9 hours ago
A bit of extra info:

- `ts` stands for "tree-sitter", meaning this mode uses tree-sitter under the hood, which is, among other things, very performant.

- There's support for the CommonMark spec and GFM, so things like `- [ ]` checkboxes and ~~strikethrough~~ work out of the box, along with many other small QoL features.

- This mode is BUILT-IN, so no extra packages are needed.

- This is currently in the experimental phase, so users need to "opt in" and load the mode to play with it, hence the first part of the guide.

dleslieabout 8 hours ago
Tree sitter support is half baked in the same way official LSP support is, only kind of worse.

Eglot won't help you get your system ready for LSP work, it will only avail itself if what's there. It doesn't even auto detect and configure that, either. There's no user prompting, so you'll have to read the docs to know that this even needs to be done.

Similarly, tree sitter support doesn't include the grammars! And those aren't typically sitting in your package repository, so users have to find a grammar and compile it themselves. There's not even a good recommendation given by Emacs on where to get them, leaving users to hope that whatever repository showed up on a Google search is both in good working order and safe to use.

It's really quite a failure on Emacs.

femiagbabiakaabout 8 hours ago
In Emacs 31 none of what you’re saying is true. Grammars auto install and setting them up is easy.

https://www.reddit.com/r/emacs/comments/1utghab/treesitter_s...

dleslieabout 8 hours ago
Well that's a nice change; I'm still on Emacs 30.

But note that this is not the default. Users have to enable that behaviour, and know to enable it. That's a bad default.

jhoechtlabout 4 hours ago
The critique converning lsp and eglot support is nonetheless true.
chroma_zoneabout 7 hours ago
If it can't find an LSP binary, Eglot will prompt you to pick one, and tell you which one it was looking for. That seems reasonable to me. I wouldn't want Emacs to download and install random binaries on my system automatically.
dleslieabout 6 hours ago
My experience with Emacs 30 is that Eglot will prompt and show nothing of meaningful assistance beyond a name. That leaves me to run a google search to find whatever binaries fit the description.

They host binaries already; why not host all of the binaries necessary for the supported features to function?

lurghtabout 8 hours ago
I think in 31 registering the file types isnt necessary any more, the mode opens automatically for me (and i did manually delete the old markdown-mode)
pjdesnoabout 10 hours ago
For those of us who have just been using Emacs, rather than following its recent evolution, "ts-mode" refers to a mode which uses tree-sitter for parsing, highlighting etc.
RahulMJabout 9 hours ago
Thanks for adding this. I just made a comment expanding a bit of what users may find in the new mode.
ggmabout 3 hours ago
So I can get bold at a cost of shift* to get the star.

Or I can do ESC enable-this-mode-option and then press a single key.

I'm struggling with this. If it's cheaper in keystrokes to type the codes inline why enable the mode?

This isn't a vi vs emacs hate thing, It's a key count efficiency thing. I don't see the motivation even if translated to minimum prefix TAB complete terms. Its like 20x more presses.

rjprinsabout 3 hours ago
I still use my markdown-modern, and obsidian-style renderer. I read more markdown than I write and for that it works well. https://github.com/rjprins/markdown-modern
taudeabout 10 hours ago
One of the biggest reason I've stopped using Emacs, and I was a pretty heavy user before was that org-mode files weren't fully native Markdown files, which caused annoying friction when collaborating with others.

It would be interesting for me to have a new markdown-centric org-mode thing. I'd love to vibe lisp to customize my workflows, and I don't totally love Obsidian, which is what I've setup and configured now. I'd prefer to just have the config living in/around init.el/config.el (I used DoomEmacs most recently).

I realize that org/agenda, etc does a ton more than markdown offers, but most of my flow is just around: raw notes to be consumed, check lists, due dates on items, and other "basics" of org-mode.

Any recent Emacsers have similar workflows that are tgenible these days? I'd love to get Emacs back in use in my new antigenic Tmux-centric coding flows, and have it be a first class markdown editor, organizaer, and potentially collaboration.....

rpdillonabout 9 hours ago
Org mode is a coherent whole, and has capabilities far beyond what Markdown can accomplish (Markdown is inherently HTML-based, org-mode is not). Markdown's history is littered with folks trying to augment it in just the right way to bring these sorts of features, which has resulted in a diaspora of flavors, none particularly dominant+powerful (which is to say, no real org-mode competitor has emerged, even though one could have). I've used Markdown and Org-mode for 20 years concurrently, and trying to make Markdown work like org-mode has never been successful for me.

I wrote a bit about this back in 2021, in response to a query on Reddit "Why didn't org-mode just use Markdown?".

https://rpdillon.net/why-doesnt-emacs-org-mode-just-use-mark...

iLemmingabout 8 hours ago
I love Org-mode and use it for many things - the outline format is great, even for some unexpected cases - Jira tickets, Slack, Reddit and HN threads, etc. But of course, hard to escape Markdown these days, so I burned some tokens to implement this https://github.com/agzam/prisma.el
mfldabout 9 hours ago
Not tested this myself, but there are ways to improve markdown/org-mode interop, like in https://youtu.be/RJqRwlVvB3E
kelvinjps10about 9 hours ago
I use markdown and nvim with telekasten plugin on desktop and mobile obsidian and for me is good enough
kodomanabout 9 hours ago
What is wrong with markdown mode? Is it that you would rather do the org agenda or calendar via md rather then org? I do understand that if that is the case.
taudeabout 9 hours ago
Yeup, I would love to have some of the org/agenda operations/views on a regular markdown file. Especially so I could just copy it raw out, and paste into other markdown-centric tools, github md files, etc. for colaborating with others.

Since markdown is becoming so prevalent. Even our product managers are becoming natively conversant with it, I'd just prefer to have as markdown first world.

(don't get me started ranting about how Atlassian and Slack have migrated away from markdown and to proprietary formats....).

kodomanabout 9 hours ago
Yes must say I have found myself moving away from org and looking at it as an annoyance wrapping up many excellent features that could be wrapped up in simple elisp function and structures that could then just be encoded in what every way one likes, it seems to me that for example todo lists are actually better as nested lisp lists, And then you can simply render as what ever you like. Of course one might like to serialize back as well but I have often wondered about it.

I definitely think markdown has won (at org was never going to 'win' of course given it's limited scope) and actually is probably what we should just all be using and accept.

edgyquantabout 10 hours ago
What are people’s workflows for using eMacs with generative coding? I’m trying to get a workflow where I can generate code and approve it like a PR (maybe leave comments for a next round of generation) but I’m new to eMacs and the ai coding package isn’t working with the latest eMacs
jwrabout 8 hours ago
I use cLaude cOde in my eMacs (through ghostel, which is unbelievably great!) to generate code :-)

I then use mAgit to review it.

remedanabout 10 hours ago
Agent Shell connected via ACP to local Claude Code.

https://github.com/xenodium/agent-shell

wilkystyleabout 10 hours ago
Can't say enough good things about agent-shell.el! Xenodium has done amazing work there.
bryanlarsenabout 10 hours ago
I'll have to try it again. It definitely feels like the right way to do things, but when I tried it it had a couple of show-stopper limitations and a show-stopper bug, so I've been using claude-code-ide.el instead.
aagabout 9 hours ago
I'm a huge fan of agent-shell, too. It keeps getting better and better, and it's infinitely customizable, like any good Emacs package.
banjomonsterabout 10 hours ago
I’ve been using gptel, I’ll have it generate org babel blocks I can tangle (write to files) or have it use tools to write and edit files in the project I’m working in, and then review with magit.
sebastianavinaabout 9 hours ago
I use windows 11, wsl2, WezTerm.

emacs -nw directly on the shell.

its like working on a linux computer, but from windows.

I run vterm inside emacs, and claude code inside vterm. I have special commands for extracting file routes, and flow between dired and magit. Everything runs like magic.

I also have copilot-chat and copilot-mode installed. From time to time I use it to review what claude has done, or to chat a little bit.

bryanlarsenabout 10 hours ago
IMO, generative coding on Emacs works nicely because magit is awesome for code review. A good agent integration package is going to have a command you can use to send the current cursor line & file to the agent so you can reference and comment.
kreyenborgiabout 10 hours ago
Which AI coding package? Agent-shell? Gptel-agent?
edgyquantabout 9 hours ago
It’s just called ai-code I’m new to eMacs so this popped up but had a bunch of issues I was trying to debug https://github.com/tninja/ai-code-interface.el
seamossfetabout 7 hours ago
just switched to doom emacs this month, absolutely loving it tbh
cpachabout 5 hours ago
“You probably heard of this new markdown-ts-mode and decided to check it out.”

Uhm, no, I haven’t.

Why should I care if the Markdown mode uses Treesitter or not…? Does it affect the performance or UX somehow?

mplanchardabout 1 hour ago
One option would be to read the section of the linked article talking about features: https://rahuljuliato.com/posts/markdown-ts-mode-emacs-31#a-q...