Skip to content

Instantly share code, notes, and snippets.

@Mon-Ouie
Created November 13, 2011 13:40
Show Gist options
  • Save Mon-Ouie/1362121 to your computer and use it in GitHub Desktop.
Save Mon-Ouie/1362121 to your computer and use it in GitHub Desktop.
(defvar yas/temp-snippet nil
"Content of the temporary snippet")
(defun yas/save-temp-snippet ()
"Saves the temporary snippet"
(interactive)
(setq yas/temp-snippet
(buffer-substring (region-beginning) (region-end))))
(defun yas/expand-temp-snippet ()
"Expands the temporary snippet"
(interactive)
(yas/expand-snippet yas/temp-snippet))
(provide 'yas-temp-snippet)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment