Created
March 3, 2014 14:36
-
-
Save danp/9326276 to your computer and use it in GitHub Desktop.
This file contains hidden or 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 new-notes-buffer () | |
| "Create and switch to a new notes buffer. Name based on current timestamp." | |
| (interactive) | |
| (switch-to-buffer | |
| (find-file-noselect | |
| (expand-file-name | |
| (concat | |
| "~/Documents/notes/notes-" | |
| (format-time-string "%Y-%m-%d-%H-%M-%S") | |
| ".txt"))))) | |
| (global-set-key (kbd "M-n") 'new-notes-buffer) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment