Created
September 17, 2015 10:14
-
-
Save myrjola/9e03f63d3dda9adb839b 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 my-org-screenshot (arg) | |
"Take a screenshot into a time stamped unique-named file in the | |
same directory as the org-buffer and insert a link to this file. | |
If arg is not nil scale down the image to fit to a smaller width" | |
(interactive "P") | |
(setq filename | |
(concat | |
(make-temp-name | |
(concat (buffer-file-name) | |
"_" | |
(format-time-string "%Y%m%d_%H%M%S_")) ) ".png")) | |
(call-process "screencapture" nil nil nil "-s" filename) | |
(when arg (call-process "convert" nil nil t "-resize" "500" filename filename)) | |
(insert (concat "[[" filename "]]")) | |
(org-display-inline-images)) | |
(defun eshell/deploy () | |
"My deploy dir" | |
(eshell/cd (concat "/ssh:alasin:/opt/deployment/new/martin-fastorm/backend"))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment