in reply to Catch the exact command line including the quotation marks and so on

hello, as Corion said is simple as saving or printing your @ARGV, bu expanding it further you can have a module specialized to this work, maybe you tell the module to write in some special history file.
# HistorySaver.pm use strict; use warnings; BEGIN{ print join " ", $^X,($^C ? '-c' : ''),(${^TAINT} ? '-T':''),$^W + ? '-w' :'',$0,@ARGV; } 1; # a true value!
Then you can use the module in all your scripts or add as command line arg:
perl -MHistorySaver -w scripts.pl --long 43 --good kawasaki

L*
There are no rules, there are no thumbs..
Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.