emacs-orgmode
[Top][All Lists]
Advanced

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

file-mode source code block header argument


From: John Herrlin
Subject: file-mode source code block header argument
Date: Fri, 24 Jul 2020 19:49:24 +0200
User-agent: mu4e 1.4.10; emacs 26.3

Hey,

I am looking for a way to set permission on a file created from source
code block result when :file header argument is used. I was looking for
something like :tangle-mode but could not find anything. I wrote a patch
that does just that and it works for my small use case. It's a header
argument called :file-mode and can be used in the same way as
:tangle-mode.

Example usage:

#+BEGIN_SRC shell :results file :file script.sh :file-mode (identity #o755)
  echo "#!/bin/bash"
  echo "echo Hello World"
#+END_SRC

Is this a suitable way of doing it?

Best regards
John

Attachment: 0001-ob-core-file-mode-option-in-source-code-block-argume.patch
Description: Text Data


reply via email to

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