Doc-org: org-mode + latex + docker = pdf

Doc-org: org-mode + latex + docker = pdf

For better formatting read this article on my website:

Why plain text is better than word processors

I was so tired of working with word processors like Microsoft Word that I created yet another a documentation system based on plain text.

With plain text you can:

  • use git
  • easily see differences between a version and another
  • use grep and other basic utilities
  • generate documents automatically with simple scripts
  • use your favorite editor

In short, with plain text I am free to do whatever I want.

Alternatives to word processors

The first thing you need in order to create a documentation system based on plain text is to choose a markup language. After many years of experiments with markdown, asciidoc and so on, I fell in love with org-mode. You can search for online demos if you don't believe me: if you are comfortable with emacs, there is nothing better than writing documents using org-mode.

Anyway, emacs does not reinvent the wheel and so there isn't a direct way to convert org-mode to pdf. What it does instead, is to translate org-mode into latex, which is the best language to create pdf files in my opinion.

So, by using emacs, you can export org-mode to latex in order to avoid writing directly in latex, which is too much verbose and it's not very readable until you export it.

This is how I have done my MSc thesis and overall I was happy of the final result. Anyway, when you try to mix your own latex customizations with latex automatically exported by emacs, it becomes a little bit difficult to achieve what you want.

That's why emacs has a body-only export option, which let you export only the body of your document. In this way you can have full control of your latex customizations.

Convincing your colleagues to migrate

So, given for granted that org-mode + latex is the best way to create pdf files you still need to convince your colleagues to install emacs and latex on their machines and to learn how to use emacs. Basically this is not possible. ??

That's why I have created doc-org, a command line utility based on docker that generates pdf files starting from org mode and latex. The only installation requirement is docker, therefore you/your colleagues don't need to install and learn how to use emacs and latex. Of course you can edit org-mode documents with any editor, you are not forced to use emacs..it's just plain text! ??

Here there are tons of example documents that are automatically generated by using github actions. Yes, you can version your small plain text files with git and then automatically build the pdf after every git push! ??

Conclusion

I am very happy I have started this project providing lots of toy examples. I hope that more companies leave behind the idea of word processors, because the best way to write documents together is the same of writing code together: plain text + version control systems like git.

Check out doc-org on github. If you have problems/suggestions just open an issue. ?? 

要查看或添加评论,请登录

Marco Ieni的更多文章

  • RustShip: a new Rust podcast

    RustShip: a new Rust podcast

    I’m excited to announce that I started RustShip: a new podcast where I interview other Rust developers to learn from…

  • 2022 recap, 2023 goals

    2022 recap, 2023 goals

    Another year has gone by, and December is the perfect time to reflect on what we’ve done in the past 12 months. Wait…

    4 条评论
  • Release-plz: release Rust packages from CI

    Release-plz: release Rust packages from CI

    Releasing Rust packages is tedious and error-prone, just like most IT manual tasks. For every package you want to…

  • CKAD: 2021 tips, vimrc, bashrc and cheatsheet

    CKAD: 2021 tips, vimrc, bashrc and cheatsheet

    You are probably busy studying for you exam right now, so I will try to be brief. In the following I will share the…

    2 条评论
  • My 2020 Recap: Open Source, talks, meetups and more!

    My 2020 Recap: Open Source, talks, meetups and more!

    I am not a huge fan of year recaps or new year’s resolutions. Mainly because I don’t like thinking about the past in…

    2 条评论
  • Rust makes cross compilation child's play

    Rust makes cross compilation child's play

    Why do I care about this Recently I solved this delta issue, where the maintainer asked to switch from Travis CI to…

  • ?? 2 videos about rust code coverage in VSCode

    ?? 2 videos about rust code coverage in VSCode

    Useless personal stuff It's several years now that I feel the need to share what I learn with other people. I gained so…

  • Create an amazing Rust GitHub project in no time

    Create an amazing Rust GitHub project in no time

    Boring introduction Expectations on open source projects are becoming higher and higher everyday. If a project is not…

  • Continuous integration with VHDL

    Continuous integration with VHDL

    Skippable introduction During this lockdown (like almost everyone) I have a lot of free time, so I decided to give a…

  • Linux on my 32GB windows tablet is surprisingly good

    Linux on my 32GB windows tablet is surprisingly good

    For better formatting read this article on my website ?? Why I removed windows from my tablet I have a HP Pavilion X2…

社区洞察

其他会员也浏览了