#!/usr/bin/perl use strict; use warnings; my $infile_name = shift( @ARGV ); print $infile_name, "\n"; #### > ./test.pl foo.txt foo.txt