News for hackers. Stuff that matters.
Re:Org-mode 9.4 is out. Can you help? by hpoe on Monday September 14, 2020 @01:30PM (#24472749)
Just want to throw out there I switched to emacs about 3 months ago after being a long time vimmer, one of the first things I was told was to check out org-mode as it was one of the greatest features of emacs.

I heartily agree, after about a month I now do all my document authoring, PDF, LaTex, HTML, personal wiki notes, all of it goes in .org files. It was low barrier to productivity, and not much more effort to turn org mode into a powerful idea and through organizer as well as documentation.

Beyond that I can author in org mode and then export to tex, to pdf, to html, to markdown to whatever I want using org mode.

If you are a long time vimmer do yourself a favor make the next tech you learn be org-mode in doom-emacs. It is insanely powerful and I will never go back.

Re:Org-mode 9.4 is out. Can you help? by jonnycomputer on Monday September 14, 2020 @04:11PM (#24474555)
I made the mistake of trying to author a scientific paper in org-mode. Big mistake. I should have just stuck with LaTeX, because what ended up happening is that all my problems and difficulties had to do with me navigating org-mode wrappers around LaTeX, when I could just have dealt with LaTeX directly.

I'm sure there will be plenty of people to tell me that I'm wrong.

Re:Org-mode 9.4 is out. Can you help? by alxlaz on Monday September 14, 2020 @04:48PM (#24474963)
IMHO (15+ years of Emacs and counting) you are not wrong.

First, Emacs already has excellent LaTeX support. Unless org-mode brings you any major advantage over plain LaTeX (which I doubt it is when you're writing a paper, that's not exactly 400 pages of loosely-coupled ideas) the extra headaches of dealing with one more intermediary language and set of packages isn't useful. If hacking on org-mode is your hobby, then yes, it's an enjoyable experience. But if you're just using it, then it's one of those cases where knowing you can is not enough, and you should maybe stop for a second and think if you should.

Second, I don't think anyone ever intended for org-mode to be used (as a wrapper) for authoring scientific papers. It's great that you can export your notes to LaTeX because it allows you to easily integrate them with existing manuscripts, it allows you have formulae embedded in them and so on. It just so happens that it's so good, and so flexible, that you can do it -- but there's no world in which a simple (no matter how flexible!) export engine for/wrapper around a language will ever be able to deal with complex matters that even said language can barely deal with.

It's one thing to use it for authoring simple documents (like blog posts), that works great. But when it takes hours of fiddling just to get the editor-supplied template to play nice with your text and figures, the last thing you need is one more moving piece.

Re:Org-mode 9.4 is out. Can you help? by danShumway on Monday September 14, 2020 @04:45PM (#24474923)
I don't think Org-mode's export features are particularly great. I'm finding that when I do want to export something, it's sometimes easier to grab a parser in a language where I'm more comfortable rather than trying to mess around with Lisp and templates.

I'm sure if I was better at Lisp my opinion would be different. But if I was writing something and wanted to target LaTeX or pure HTML, I'm not sure I would use Org-mode as the source unless I was writing the converter myself. I think I'd just write in HTML/LaTeX directly.

That being said, I would probably still stick all of my notes, references, and TODOs for a scientific paper in Org-mode, and then use LaTeX just for the final paper. The fact that Org-mode can do text references like

  * TODO Find facts about bees

  Need more details at file:~/final.tex::And another thing about bees

  References checklist:

  - [ ] https://google.com
  - [X] https://duckduckgo.com
  - [ ] https://wikipedia.com
means that Org-mode ends up being more useful for me as a surrounding 'notebook' around my projects rather than as the core format I'm authoring everything in.
Re:Org-mode 9.4 is out. Can you help? by eigenhombre on Monday September 14, 2020 @04:47PM (#24474958)
I've written a few hundred Org mode docs, and a doctoral thesis in LaTeX.

I would not write a complex technical paper in Org Mode, other than just to get my thoughts together initially to eventually copy/paste into LaTeX.

But, Org Mode is good enough for most of my writing over the last several years. It is more readable as plain text, and exports to HTML or PDF trivially (the latter via the LaTeX export hook). I like it enough that I use it as the basis of my blog, exporting each article to HTML and then massaging the HTML programmatically to generate static files styled and cross-linked the way I want. This approach gives me math formulas via MathJax, still images, tables, code snippets... basically everything I want for a somewhat tech-y blog.

But, yeah, if you're going to just write a full-on technical paper for publication, I'd go right to LaTeX.

Re:Org-mode 9.4 is out. Can you help? by _emacsomancer_ on Monday September 14, 2020 @09:54PM (#24477144)
I agree with this. I often write up notes in Org mode, but, after trying for a while to have all of my 'sources' in Org, I also came to the conclusion that for actual papers, it's far better just to write them directly in LaTeX (other than initial notes).
Re:Org-mode 9.4 is out. Can you help? by Myrmornis on Monday September 14, 2020 @07:31PM (#24476326)
Plug: I've been working on a new LaTeX-editing minor mode to use in conjunction with auctex:

https://github.com/dandavison/xenops

It's basically a replacement for preview-latex: it renders math/TikZ/table fragments automatically and asynchronously. If any emacs-lisp programmers who are interested in LaTeX editing would like to help out please get in touch!

Re:Org-mode 9.4 is out. Can you help? by sqrt17 on Monday September 14, 2020 @04:37PM (#24474858)
What pain points would it have saved to write the scientific paper in org-mode? Usually there's a dozen dirty little corners where you want fine-grained control and the org-mode-to-latex converter isn't giving you that by default.

I once wrote a short report that I (probably) could also have written in (any equivalent of) Word or LyX/TeXmacs, or some random WISYWIG editor. Very little finetuning of the layout required or necessary, people still liked it better than plaintext (it had some headlines and tables and stuff, but nothing too fancy). So, nice output yes but be careful if what you need is actual LaTeX document preparation.

Re:Org-mode 9.4 is out. Can you help? by na85 on Monday September 14, 2020 @08:05PM (#24476545)
>What pain points would it have saved to write the scientific paper in org-mode?

For me, latex is the pain point. I don't want to have to read through pages of inscrutable error messages about overfull mboxes and then read dozens of contradictory stack overflow answers for outdated versions that only half-address the problem I'm having.

Re:Org-mode 9.4 is out. Can you help? by why-el on Monday September 14, 2020 @04:40PM (#24474878)
I think you are correct. I do everything personal in org-mode, but I switch to manual if the doc ends up being shared. Heck, I even elect to use google doc if I have at least one collaborator.
Re:Org-mode 9.4 is out. Can you help? by eigenhombre on Monday September 14, 2020 @04:49PM (#24474970)
This for me is the biggest pain-point about Org Mode -- most of my colleagues won't touch it, so it's off to Google Docs we go....
Re:Org-mode 9.4 is out. Can you help? by kindahero on Tuesday September 15, 2020 @02:48PM (#24485136)
Oh I know the pain, I did the same back in 2015. That was my first scientific paper ever. Then "never again" said to myself. Now I use pure latex. org-mode is only good for quick exports should not think it as an alternative to latex.
Re:Org-mode 9.4 is out. Can you help? by dan-robertson on Monday September 14, 2020 @04:40PM (#24474881)
I think that’s probably reasonable. Fortunately, AUCTEX mode works well for latex so the main loss is org’s document structure management and maybe syntax. I don’t know if there’s a way to get that in AUCTEX
Re:Org-mode 9.4 is out. Can you help? by ArneBab on Tuesday September 15, 2020 @08:27AM (#24480422)
I authored my PhD in org-mode, where the planning and re-structuring provided huge benefits. But for the shorter paper I just used LaTeX.
Re:Org-mode 9.4 is out. Can you help? by bachmeier on Monday September 14, 2020 @04:57PM (#24475066)
I'd never author a paper directly in latex. That would suck. I'd author in Pandoc markdown, convert to latex, and then add tables and whatever using latex around it. It's pretty painful IMO to write documents in latex vs markdown.
Re:Org-mode 9.4 is out. Can you help? by ArneBab on Tuesday September 15, 2020 @08:30AM (#24480453)
In that case you have a perfect example of starting with org-mode instead: Then you can already add tables and images and all the stuff and have much less finetuning to do:

- create draft in org - export to LaTeX - polish for publication

Re:Org-mode 9.4 is out. Can you help? by tomerbd on Monday September 14, 2020 @01:35PM (#24472791)
Can you copy and paste an image into org mode? In many of my document/notes I find that I to copy and paste images into my documents like I take a screenshot and then paste..
Re:Org-mode 9.4 is out. Can you help? by zzamboni on Monday September 14, 2020 @03:51PM (#24474329)
Yes, with the org-download module (https://github.com/abo-abo/org-download). I have some additional configuration to paste a screenshot (asking for a filename) using a keybinding. Here is my config: https://github.com/zzamboni/dot-doom/blob/master/doom.org#ca...
Re:Org-mode 9.4 is out. Can you help? by WhatIsDukkha on Monday September 14, 2020 @01:51PM (#24473016)
There are plenty of ways to do it -

https://github.com/abo-abo/org-download

Re:Org-mode 9.4 is out. Can you help? by proxygeek on Monday September 14, 2020 @01:47PM (#24472954)
If you use it on Windows and have Itfanview installed, here's is how you can do it to copy paste images from clipboard using C-c-s

(defun my-org-screenshot () "Take a screenshot into a time stamped unique-named file in the same directory as the org-buffer and insert a link to this file." (interactive) (setq screenshot_dir ".\\images\\") (setq tilde-buffer-filename (replace-regexp-in-string "/" "\\" (buffer-name) t t)) (setq filename (concat (make-temp-name (concat screenshot_dir tilde-buffer-filename ;; attempt to make irfanview approach work "_" (format-time-string "%Y%m%d_%H%M%S_")) ) ".png")) (insert (concat "[[file:" filename "]]")) (org-display-inline-images))

(global-set-key "\C-cs" 'my-org-screenshot)

Re:Org-mode 9.4 is out. Can you help? by boogies on Monday September 14, 2020 @02:15PM (#24473282)
Could you indent your Lisp by four spaces for formatting?

    (Like this)
Re:Org-mode 9.4 is out. Can you help? by dan-robertson on Monday September 14, 2020 @02:49PM (#24473643)
On HN you only indent two spaces to turn on monospace.

Here is the lisp with formatting:

  (defun my-org-screenshot ()
    "Take a screenshot into a time stamped unique-named file in the same directory as the org-buffer and insert a link to this file."
    (interactive)
    (setq screenshot_dir ".\\images\\")
    (setq tilde-buffer-filename
          (replace-regexp-in-string "/" "\\" (buffer-name) t t))
    (setq filename
          (concat
            (make-temp-name
              (concat screenshot_dir
                      tilde-buffer-filename ;; attempt to make irfanview approach work
                      "_"
                      (format-time-string "%Y%m%d_%H%M%S_")))
            ".png"))
    (insert (concat "[[file:" filename "]]"))
    (org-display-inline-images))
Re:Org-mode 9.4 is out. Can you help? by vz8 on Monday September 14, 2020 @02:38PM (#24473525)
Did you mean Irfanview?

Thanks for the tip. Mostly emacsing via X, but good to know.

Re:Org-mode 9.4 is out. Can you help? by tobbe2064 on Monday September 14, 2020 @02:00PM (#24473120)
I just jumped to emacs from vim last week and this was one of the reasons, yes it is possible to display images!

I wa salso curios about org-roam but I'm letting it sitt for a while

Re:Org-mode 9.4 is out. Can you help? by hpoe on Monday September 14, 2020 @01:41PM (#24472872)
No, org mode is text based; however what you can do is link to an image, and then when you publish the org mode file as html, or pdf or whatever it will get interpolate and appear as though it had been pasted in.

At least that has been my experience a more seasoned orger can correct my ignorance if I do err.

Re:Org-mode 9.4 is out. Can you help? by ycombinete on Monday September 14, 2020 @01:50PM (#24473006)
Org mode supports inline images. See more here: https://stackoverflow.com/questions/27129338/inline-images-i...
Re:Org-mode 9.4 is out. Can you help? by helloSam43 on Wednesday September 16, 2020 @01:16PM (#24494807)
Hi, also big fan of org-mode authoring, but how do you import/modify/use nice latex templates such as invoice or resume? https://www.latextemplates.com/template/invoice ?