Skip to content

Instantly share code, notes, and snippets.

@miyamuko
Created July 12, 2010 14:07
Show Gist options
  • Save miyamuko/472503 to your computer and use it in GitHub Desktop.
Save miyamuko/472503 to your computer and use it in GitHub Desktop.
;; meadow で開く
(defun meadow()
(interactive)
(let* ((emacs-dir (read-registry "SOFTWARE\\GNU\\Meadow\\netinstall3" "emacs_dir" :local-machine))
(runmw32 (merge-pathnames "bin/RunMW32.exe" emacs-dir))
(file (get-buffer-file-name (selected-buffer))))
(if file
(call-process (format nil "~A +~A:~A ~A"
runmw32 (current-line-number) (current-column) file))
(call-process runmw32))))
;; メモ帳で開く (メモ帳トラッパー対応)
(defun notepad ()
(interactive)
(let* ((mmtrp (merge-pathnames "system32/mmtrp.cpl" (get-windows-directory)))
(notepad (merge-pathnames
(if (file-exist-p mmtrp) "system32/notepa~.exe" "system32/notepad.exe")
(get-windows-directory)))
(file (get-buffer-file-name (selected-buffer))))
(if file
(call-process (format nil "~A ~A" notepad file))
(call-process notepad))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment