ytjPerl has asked for the wisdom of the Perl Monks concerning the following question:
use strict; use warnings; use lib "D:/App/Perl/lib//"; use autodie; use Capture::Tiny 'capture_merged'; use POSIX; use constant DATETIME => strftime("%Y%m%d%H%M%S", localtime); my $input = "D:/log_script/tuxedo_logs/startup" . DATETIME . ".log"; open ( my $file, ">>", $input )or die "cannot open $!"; chdir "D:/server/setup"; print $file capture_merged { system('setenv.cmd&&tmboot -y') }; close($file); `
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: can't open file for appending
by stevieb (Canon) on Aug 14, 2017 at 16:02 UTC | |
|
Re: can't open file for appending
by Mr. Muskrat (Canon) on Aug 14, 2017 at 18:24 UTC |