in reply to How to pass directory variable using IPC::System::Simple
Why do you import IPC::System::Simple? Maybe that module can export a subroutine foldername?
I recommend that you construct and print the filename before trying to launch the external program. For example:
my $date = '2016-07-25'; my $filename = "$savedir/TEST-$date.jpg"; system(...);
To get at the current date, the easiest approach is to use the strftime function from the POSIX module:
my $date = strftime '%Y-%m-%d', localtime; ...
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: How to pass directory variable using IPC::System::Simple
by bill5262 (Acolyte) on Jul 25, 2016 at 07:39 UTC | |
by haukex (Archbishop) on Jul 25, 2016 at 08:46 UTC |