Function: ebrowse-save-tree-as
ebrowse-save-tree-as is an autoloaded, interactive and byte-compiled
function defined in ebrowse.el.gz.
Signature
(ebrowse-save-tree-as &optional FILE-NAME)
Documentation
Write the current tree data structure to a file.
Read the file name from the minibuffer if interactive. Otherwise, FILE-NAME specifies the file to save the tree in.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/progmodes/ebrowse.el.gz
;;;###autoload
(defun ebrowse-save-tree-as (&optional file-name)
"Write the current tree data structure to a file.
Read the file name from the minibuffer if interactive.
Otherwise, FILE-NAME specifies the file to save the tree in."
(interactive "FSave tree as: ")
(let ((temp-buffer (get-buffer-create "*Tree Output"))
(old-standard-output standard-output)
(header (copy-ebrowse-hs ebrowse--header))
(tree ebrowse--tree))
(unwind-protect
(with-current-buffer (setq standard-output temp-buffer)
(erase-buffer)
(setf (ebrowse-hs-member-table header) nil)
(insert (prin1-to-string header) " ")
(mapc #'ebrowse-save-class tree)
(write-file file-name)
(message "Tree written to file `%s'" file-name))
(kill-buffer temp-buffer)
(set-buffer-modified-p nil)
(ebrowse-update-tree-buffer-mode-line)
(setq standard-output old-standard-output))))