zyedidia / micro

A modern and intuitive terminal-based text editor
https://micro-editor.github.io
MIT License
24.85k stars 1.17k forks source link

micro as a latex editor ? #1295

Open taz4hvn opened 5 years ago

taz4hvn commented 5 years ago

hi,

I just discovered micro and love it so far. I'm trying to use it as a latex editor with, say zathura, as a pdf viewer. I succeeded to bind a compil key by adding in bindings.json:

"F5": "Save,command:run latexmk -pdfps",

But I can't even launch zathura to open the compiled pdf, because I don't find something like %f or %filename in all the micro docs. What I want to achieve is a bi-dir synctex search between micro and zathura. I can open micro at the correct position from zathura but how do I do the reverse ?

thx

mardukbp commented 3 years ago

%f is available in the Lua API. See how it is used in the linter plugin.

Maybe you can kick off the development of the LaTeX plugin for micro :)

chykcha3 commented 1 year ago

Hi!

I recently started to use micro as latex editor as well, with zathura as a viewer. I wrote a plugin that lint, compile and open .pdf file in zathura with enabled synctex, both forward and backward. Here is the link to the plugin https://github.com/chykcha3/micro-plugin-latex.

I write a comment here to help someone who wants to use micro and latex, because I cannot consider this plugin ready enough to propose it to the official plugin channel. And finally, I am very new to lua and go, so I will be glad if someone is interested to work on this plugin too. This plugin works for me and covers my needs, so now I have almost no motivation to improve it, but it would be cool to create smth better, if there is somebody else who also interested in it.