I hope to let org-babel can tangle to root permission file with tramp-sudo support like the following format:
#+BEGIN_SRC clojure :dir /sudo:: :tangle "/etc/kk.clj"
...
#+END_SRC
But it does not work. How to implement this?
Here is the error:
Debugger entered--Lisp error: (file-error "Removing old name" "Permission denied" "/etc/nginx/conf.d/kk.clj")
#<subr delete-file>("/etc/nginx/conf.d/kk.clj" nil)
ad-Advice-delete-file(#<subr delete-file> "/etc/nginx/conf.d/kk.clj")
apply(ad-Advice-delete-file #<subr delete-file> "/etc/nginx/conf.d/kk.clj")
delete-file("/etc/nginx/conf.d/kk.clj")
... [assoc 4] 6 "\n\n(fn SPEC NAME)"] :tangle :shebang 0 :tangle-mode "yes" file-name-sans-extension "no" nil "." :mkdirp file-name-directory make-directory parents file-exists-p mapcar car delete-file generate-new-buffer " *temp*" make-byte-code "
...
mapc(....
org-babel-tangle((4))
funcall-interactively(org-babel-tangle (4))
call-interactively(org-babel-tangle nil nil)
command-execute(org-babel-tangle)
conf
requires loading a package ´ob-conf.el` or something like this. Could you show the complete example and the error message?