in reply to Perl calling Linux commands

chomp(my $username = <>); # ... etc

See chomp.

package Cow { use Moo; has name => (is => 'lazy', default => sub { 'Mooington' }) } say Cow->new->name