shithub: riscv

ref: 4fb65ae3e84f536a9b924082b7c59a30d5802e6b
dir: /sys/src/cmd/python/Doc/tools/fixinfo.el/

View raw version
(defun fix-python-texinfo ()
  (goto-char (point-min))
  (replace-regexp "\\(@setfilename \\)\\([-a-z]*\\)$"
		  "\\1python-\\2.info")
  (replace-string "@node Front Matter\n@chapter Abstract\n"
		  "@node Abstract\n@section Abstract\n")
  (mark-whole-buffer)
  (texinfo-master-menu 'update-all-nodes)
  (save-buffer)
  )	;; fix-python-texinfo

;; now really do it:
(find-file (car command-line-args-left))
(fix-python-texinfo)
(kill-emacs)