Just annotations of little "how to's", so I know I can find how to do something I've already done when I need to do it again, in case I don't remember anymore, which is not unlikely. Hopefully they can be useful to others, but I can't guarantee that it will work, or that it won't even make things worse.
Pseudo-template noob hack that may apply for several situations
There's a painting software, "mypaint", which is very nice, but it does not support templates, at least not yet.
I've created a template (just a "blank" file with the correct resolution and whatnot) on GIMP, saved it as "ora", but instead of opening this file manually every time, and remembering to save it with a new name in order to not overwrite the template, I came up with a script that will create a new name automatically, with no risk of overwriting the template.
Then you can add some application menu entry pointing to this script, or even a submenu with several template options, given as parameters to the script ($1).
I've created a template (just a "blank" file with the correct resolution and whatnot) on GIMP, saved it as "ora", but instead of opening this file manually every time, and remembering to save it with a new name in order to not overwrite the template, I came up with a script that will create a new name automatically, with no risk of overwriting the template.
Code:
template=$1 export DISPLAY=:0 # I'm not really sure it's needed or why it's there anymore filename="$(date '+%y%b%d-%H%M').ext" # creates a filename based on the time and day you run the script cp "/path/to/your/$template" "/dev/shm/$filename" && # just in case you don't end up saving the new work from the template, it copies it first to the memory whatever-program "/dev/shm/$filename" & while true ; do inotifywait /dev/shm/$filename && cp /dev/shm/$filename /path/to/destination/folder/ # if the file on /dev/sh (memory) is changed (when you save it), it's copied to a given destination folder on the hard drive. done
Then you can add some application menu entry pointing to this script, or even a submenu with several template options, given as parameters to the script ($1).
Total Comments 2
Comments
-
okay here's where you must finally learn to not use such predictable names.
Posted 04-12-2012 at 11:48 PM by Web31337 -
Uh?
Posted 04-13-2012 at 05:36 PM by the dsc