You'll want to look at @ARGV in perlvar and opendir, readdir.
In reply to Re: Directory name as command line argument by kyle in thread Directory name as command line argument by max210