$ pamac list -o | awk '{ total += $4 }; END { print total }'
143,9
but the result is wrong due to different units (kB and MB in this example).
Any chance to have unique units or another possibility to calculate the total?
Thank you and regards, Michael