unnecessary scrot wrapper - Programming On Unix
Users browsing this thread:
|
|||
I wrote a scrot wrapper because I am horrible at keeping my file system clean. I also explained it really badly on the README, but basically it creates subdirectories of whatever the $NOUGAT_SCREENSHOT_DIRECTORY is set to as needed. Organizes screenshots by year, month, and day.
Taking a screenshot would today would create a 2017 subdir, then within 2017 it would create September, and then within September it would create 07. I wasn't too sure if any one else would use this, but figured it was worth sharing. Oh yeah, and it symlinks all the screenshots to an "all" directory (which is a subdir of $NOUGAT_SCREENSHOT_DIRECTORY) so you don't have to hunt down images forever. It can also place images in /tmp with the '-t' option. Here it is, if anyone is interdasted: click also someone please send help I've been living in vim for the past week or so and keep typing ":w" in this text box |
|||
|
|||
(07-09-2017, 06:22 AM)Sweets Wrote: Taking a screenshot would today would create a 2017 subdir, then within 2017 it would create September, and then within September it would create 07.Sounds good. I'm not so found of that line: Code: echo "scrot $scrotopts" | /bin/bash (07-09-2017, 06:22 AM)Sweets Wrote: also someone please send help I've been living in vim for the past week or so and keep typing ":w" in this text boxI keep doing that on irc, most of the time ironically. Code: ctrl-[:w |
|||
|
|||
Good job. I think i will use this. But I will modify the final filename to include, hour:minute:seconds, since i seldom hit the target on my first scrot so to speak.
I have been thinking about doing something similar for my dotfiles, but in one way the opposite: * Moving selected file (f.i. ~/.bashrc) to an all folder (in my case a dropboxfolder), and rename the file. * Then symlink it back to it's original location, with original name. * And put symlinks in "tag folders". With this it will be really easy to browse the files with dmenu or similar. I always have a backup on dropbox, and i think i will upload the tagfolders to github. I will select files, with a script that gets the filename of the open file in Sublime Text, and ask for actions with dmenu. "You don't nix if you don't script" |
|||
|
|||
(07-09-2017, 06:33 AM)venam Wrote: [quote="Sweets" pid="18894" dateline="1504776169"] I wish I could say my usage of :w was ironic. Also, is there a better way to write the line? I did try a few things, such as just using Code: scrot $scrotopts Quote:giblib warning: unrecognised option $f I think it's an issue in the way I concatenated when setting up scrotopts, but I'm not too sure. Bash is definitely not my strongest language. (07-09-2017, 06:37 AM)budRich Wrote: Good job. I think i will use this. But I will modify the final filename to include, hour:minute:seconds, since i seldom hit the target on my first scrot so to speak. I've sort of experimented with that with this installation. Very bad idea admittedly, but fun to play around with. Changed the root directory to be "/os", and symlinked everything but /dev, /tmp, /users (my /home), and /sys (systemd! >:( ). Also, awesome to see that at least one person is interested in using the wrapper. I didn't imagine even a single person would be very interested since it's an almost completely unnecessary wrapper. |
|||