in reply to Eliminating Trailing Zeros
s/(?:(\.\d*[1-9])|\.)0+\z/$1/; [download]
Makeshifts last the longest.