Guest User

Untitled

a guest
May 27th, 2018
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.88 KB | None | 0 0
  1. #+BEGIN_SRC emacs-lisp :results none
  2. (setq properties-list '("Title" "Composer" "Publisher" "NDisks"))
  3.  
  4. (let ((MATCH t)
  5. (SCOPE 'file)
  6. (SKIP nil)
  7. (spacing nil))
  8. (org-map-entries
  9. (lambda ()
  10. (let ((level (nth 1 (org-heading-components))))
  11. (if (= level 3)
  12. (save-restriction
  13. (org-narrow-to-subtree)
  14. (goto-char (point-max))
  15.  
  16. (org-insert-heading)
  17. (insert "New Entry\n")
  18. (dolist (property properties-list)
  19. (org-entry-put (point) property nil)
  20. )
  21. ;; now cut tree and paste at level 4
  22. (org-cut-subtree)
  23. (org-paste-subtree 4)
  24. )))) MATCH SCOPE SKIP))
  25. #+END_SRC
  26.  
  27. ** Class One
  28. *** Student 1
  29. **** Essay 1
  30. *** Student 2
  31. *** Student 3
  32. **** Essay 1
  33. ** Class Two
  34. *** Student 1
  35. *** Student 2
Add Comment
Please, Sign In to add comment