I am currently in Afghanistan and do not have access to some of the resources I normally do back in the US. Just accessed this site and it looks promising! Hopefully you will not find my question too much of a waste of your time.
I write mostly Korn Shell and PERL on Solaris systems for the Army. There are times when writing in one language you run into a wall and really need to do something in another. I have been using this method when in PERL to insert ksh mini-scripts and subroutines:
#!/usr/bin/perl
print �This proves I am writing in PERL... enter something
---> �;
chomp($file=<STDIN>);
print �\n$file\n�;
system(<<EOF); # Will run system commands until EOF
echo \n
ps -ef | grep -i oracle | sed �G;G'
EOF
print �\nBack in PERL!\n�;
Is there a similar method to call PERL from a ksh script besides perl -e? I have tried variations of the above method and although I can call PERL with:
perl <<'EOF'
print "
----> \n";
chomp($file=<STDIN>);
print "$file";
EOF
The print statement works but the $file=<STDIN> doesn't. I have tried back ticks, escaping the $, etc and nothing works. Any suggestions?