$InputFileName

$InputFileName
is the name of the file from which input is currently being read.

While in interactive mode, $InputFileName is “”.