Created
October 6, 2008 01:56
-
-
Save ivey/14975 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun gist-region-or-buffer () | |
"Post either the current region, or if mark is not set, the current buffer as a new paste at gist.github.com | |
Copies the URL into the kill ring." | |
(interactive) | |
(condition-case nil | |
(gist-region (point) (mark)) | |
(mark-inactive (gist-buffer)))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment