guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#38616] emacs: fix odt export


From: Nicolò Balzarotti
Subject: [bug#38616] emacs: fix odt export
Date: Sun, 15 Dec 2019 00:45:09 +0100

Hello Guix!

Neither on NixOS or in guix I've ever been able to export an org file to
otd. The error was
'OpenDocument export failed: Buffer is read-only: #<killed buffer>'.

I've seen some report of this error on the web, like:
- https://lists.gnu.org/archive/html/emacs-orgmode/2018-05/msg00545.html
- https://github.com/syl20bnr/spacemacs/issues/1482

but also on our IRC:
- http://logs.guix.gnu.org/guix/2019-05-07.log
- http://logs.guix.gnu.org/guix/2019-07-25.log
but I was not able to find a fix for it.

Today I checked the source and figured it out. The explanation, as
written in the patch, is the following

> Files inside the guix store are read only. "styles.xml" is copied from the
> store (/share/emacs/26.3/etc/org/OrgOdtStyles.xml), so it's read only too.
> ox-odt needs this file, so if it's not writable it will fail. This patch
> adjust the permissions.

So, this patches fixes the permissions on the file.

I've two questions:
1. Is it fine to have a .patch, or should I add a phase where I fix the
   file? this seemed to be easier
2. If the same error happens for other programs, might it make sense to
   "fake" rw permissions in the store (by using a virtual fs or
   something) so that files are copied as rw, but files in the store are
   still ro?

Thanks!

Nicolò

Attachment: 0001-gnu-packages-emascs.scm-emacs-patches-Fix-odt-export.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]