-
Notifications
You must be signed in to change notification settings - Fork 179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Automatic conversion to LaTeX source #249
Comments
This concept makes sense for submitting to journals that prefer LaTeX over DOCX for submissions. It should be feasible because you are correct that pandoc supports conversion to tex. We could add a manubot/manubot#68 discussed some earlier attempts to generate tex. We would need to work on a stable way to get LaTeX working in the continuous integration environment or use a Docker environment for this step. In the short term, we could also work on an example pandoc command to guide users who want to do this outside of the build script as a final step before journal submission. |
Perhaps |
There are two steps here I believe:
It sounds like 1 is what is necessary for submission to journals, although 2 would be nice so the LaTeX compiler could detect errors and you could view the output PDF to make sure everything converted properly. @slochower do you have an implementation of either of these steps? How much will users need to customize these steps? How does customization work / at what stage... isn't there some way to apply a template/style for a specific journal? |
The big benefits of adding LaTeX support that I see are:
|
Point 1 is (relatively) easy, as you say. We can just use
IIRC, Point 2, also as you point out, is a little more tricky. I implemented it this way:
But I did not have this running via CI (only locally). Here I used Regarding |
Another benefit of supporting LaTeX could be enabling Manubot-based writing of documents that have precise formatting requirements, like grant applications or university dissertations. I haven't tested this so it's unclear to me how much the pandoc tex template helps with that or whether the final formatting steps would have to be manual after the content is finalized. Perhaps this is the same idea as "branded PDFs" above. |
@agitter agreed, although I found the |
@slochower for the |
I think using the output of |
Here's a useful resource on different ways to install LaTeX on Travis CI. It mentions |
I've got the Setting |
Usually, from what I've seen submission systems that can ingest |
I'd also really like to have a LaTeX file as output, so I don't have to fiddle with If |
@habi I propose the simplest possible LaTeX export in #384. In #256, I tried to get the LaTeX to compile and render as PDF, which proved challenging. But perhaps having a |
* setup.bash: interactive script to guide setup merges manubot/rootstock#417 closes manubot/rootstock#401 * Add "gh repo create" to SETUP.md merges manubot/rootstock#419 closes manubot/rootstock#418 Co-authored-by: Daniel Himmelstein <[email protected]> Co-authored-by: Anthony Gitter <[email protected]> * BUILD_LATEX for basic LaTeX manuscript merges manubot/rootstock#384 refs manubot/rootstock#249 * Pandoc 2.14: update HTML plugins, CSL style, citekey syntax merges manubot/rootstock#427 Co-authored-by: Daniel Himmelstein <[email protected]> Co-authored-by: Anthony Gitter <[email protected]> Co-authored-by: nfry321 <[email protected]> Co-authored-by: Tiago Lubiana <[email protected]> Co-authored-by: Daniel Himmelstein <[email protected]> Co-authored-by: Anthony Gitter <[email protected]> Co-authored-by: Vincent Rubinetti <[email protected]>
I'm sharing some notes from our Manubot manuscript that we exported to LaTeX for a conference submission. There are more details at greenelab/covid19-review#943. We customized a LaTeX template for the conference style. Like @slochower, we also found the templating system cumbersome. The Manubot metadata didn't perfectly fit the template expectations so we had a bidirectional process of modifying the template and the metadata. Getting the authors to show up correctly was the trickiest part. We created a new metadata.yaml file using a Python script, in part because we were already modifying metadata.yaml programmatically because this conference submission was one piece of a larger project. It's very helpful that newer versions of pandoc can convert the CSL JSON file Manubot produces into a .bib file. I typically submit a .bib file to a conference or journal instead of embedding references in a .tex file. We added this conversion step to the build script. We used a regex to strip out the We didn't try to build a PDF with continuous integration. We used Manubot to get 95% of the way to submission automatically and then fine-tuned LaTeX issues in Overleaf before submitting. |
Here's an alternative way, if possibly more buggy: If you use markdown module for lualatex (which is easily enabled in Overleaf), you can operate in "dual" mode by having an alternative There will be some fights over things like figures and internal references. See https://github.com/stain/ro-crate-paper/blob/master/latex/ro-crate.tex and workarounds for manubot in https://github.com/stain/ro-crate-paper/blob/master/build/build.sh#L14 This allowed us to edit the manuscript in Overleaf, while also having Manubot rendering using the Overleaf-GitHub sync You have been warned - this approach will let you conform to the journal style - but will also come with lots of new caveats. |
For some research fields, like math or theoretical physics, one must submit the LaTeX source of the manuscript for publication in, eg. APS journals. It would therefore be very convenient if manubot could also have a LaTeX + BibTeX conversion mode for such cases. iirc
pandoc
supports conversion to TeX?The text was updated successfully, but these errors were encountered: