aliquote

< a quantity that can be divided into another a whole number of time />

September 8, 2022

Tip of the day: If you want to get ride of Ubuntu putting screenshots with arbitrary filenames in arbitrary folder, without resorting on the good old gnome-screenshot tool, just use:

% xdg-user-dirs-update --set PICTURES ~/Media/Pictures
% cd ~/Media/Pictures/Captu*  ## NOTE: update according to your settings
% rename 's/Capture\ d’écran\ d[eu]\ //g;s/\s/-/g' *

Don’t forget to update the last instruction to reflect basename on your system, use a Makefile or shell script to automate the process. Usually, Ubuntu will create a subfolder (“Screenshots” or “Captures d’écran” or whatever) in the default PICTURES folder. What’s funny is that instead of a straight single quote, Ubuntu decided for whatever reason to use a curly quote!

I used to use the following Bash script on X11, but it no longer works under Wayland:

scrot '%Y-%m-%d-%H-%M-%S.png' --thumb 300x200 -e 'mv $m $f ~/Media/Pictures/screenshots'

Here, screenhots is a soft link to the default subfolder where screenshots are saved.