stardiviner <> writes:

> Hash: SHA256
> George Mauer <> writes:
>> With VSCode becoming ever-popular it seems like there might be some value
>> in getting org mode working there simply as a way of promoting org as an
>> excellent literate coding notebook.
>> VSCode already has a halfway decent org-mode but it doesn’t support
>> anything from Babel. I’m trying to think of relatively easy ways of adding
>> that ability. Here’s a thought: Most of babel that technically works
>> against the document itself, it doesn’t really need much document
>> integration with the editor. So could you get it working in vscode so long
>> as someone has a properly configured version of emacs installed locally?
>> “Evaluate/Export/etc” would just write the document, then use emacs to run
>> the appropriate commands on it and refresh the document view.
> Use Emacs as backend for Org Mode Babel to run in VS Code, This sound a bit of
> overthinking. Why not just use Org Mode in Emacs directly? As my personal
> opinion, Org Mode is just a document format (of course it's deeply integrated
> with Emacs!!) But VS Code can do it in similar way. I really suggest you think
> it clearly. And help VS Code team archive this.

I think the main flaw in using Emacs as the backend is that a correctly
configured emacs to support or the org features, especially wrt babel
and document export, is a non-trivial task. It is not as simple as
installing Emacs and a couple of setq lines in an init file.

Org relies heavily on a lot of external tools, especially TeX/LaTeX.
Anyone who is going to put in the effort to configure Emacs is unlikely
to want to also configure VSCode and vice versa, plus you would need to
run both VSCode and at least the emacs server/daemon to make this work.

Having said that, it could be an OK proof of concept to perhaps spark
interest in developing a VSCode version which has the babel/export
features (I'm assuming the existing implementation already handles the
basic org markup syntax etc). In the long term, a VSCode version of org
would probably benefit more if it uses other VSCode plugins for babel
and export. Starting with the languages which have REPLs would likely be
a good first step and I suspect there is already a LaTeX plugin. It will
likely be necessary to work with the various authors of these other
VSCode plugins as you will probably need them to add additional API
hooks to use. 

Probably the best assistance org-mode can provide would be definitive
and current documentation on the markup syntax and APIs for babel and
export. A tough task given the scope, but things are probably pretty
stable in this area now (though I'm not sure about babel and handling of
returned values and errors etc). 

Tim Cross

Reply via email to