yes, but I'm trying to do it internal of the script.
I'm thinking:
but I'm concerned with running into resource issues as sometimes the output of foo can be very large. I was hoping there was another approach.
Hi,
I am a beginner in Perl programming. Now i need to call a C program from a perl program ...Can any one please help me and give any details how i can do this.
Thanks and Regards (3 Replies)
Are the programs written on schedulers ,thread library , process management, memory management, et al called systems programs ? How are they different from the programs that implement functions like open() , printf() , scanf() , read() .. they have a prefix sys_open, sys_close, sys_read etc , right... (1 Reply)
I am trying to run a program called GMT using perl. Cannot make to run. I have tried using exec("date"); as a test but when I use exec($try); nothing happens.
#!/usr/bin/perl
print "$#ARGV\n";
if ($#ARGV != 3) {
print "usage: jcdplot.perl\n";
exit;
}
$h = $ARGV;... (1 Reply)
Hi All,
I have just started learning perl and was working on my one-liners tips and tricks.
Instead of using the below command :
perl -lape 's/(^From:).*/$1 Nelson Elhage <nelhage\@ksplice.com>/'
i tried using the \k command using the below command but it gave no results:
perl -lape... (2 Replies)
I am trying to work with a text file which has following format and trying ti run if elseif loop but fails. Any help is appreciated
289B ship N-grp 123
289C ship N-grp 123
289D ship N-grp 123
2CE1 flight N-grp 123
2CE2 flight N-grp 123
2CE3 flight N-grp 123
2CE4 flight N-grp 123
2DAF... (4 Replies)
Guys,
i was trying a simple if-then-else statement in perl; but not getting any success in that.
can you please help, where i am wrong. I tried $diff variable with double quotes as well, but no go.
$region = $ARGV;
$diff = $ARGV;
if ; then
($date) = split(' ', `ssh -xC $san cat... (2 Replies)
Hi all
I tried to remove duplicates using all code mentione dbelow but its not wroking it's seems busy please check it
sort -u filename.txt
perl -lne 'chomp; if(!defined $x{$_}){$x{$_}=1;print}' inputfile
out of attached files
log file(input)
log2file(output) (9 Replies)
have issue where my elsif is always failing. Basically i have a file with sets of 2 lines, the 1st line that containing "ipwr" and the 2nd line containing a value or "unknown". if the 2nd line contains a value then i want to print the pair of lines.
open (INFO, "temp.txt") or die;
... (3 Replies)
Hey guys,
Suppose i run passwd via bash shell. It is a suid program, which temporarily runs as root(owner) and modifies the user entries.
However, when i write a C file and give 4755 permission and root ownership to the 'a.out' file , it doesn't run as root in bash shell. I verified this by... (2 Replies)
Experts - I have a snippet of code I can't figure out. I was hoping someone could help me here.
I have a file of IPv6 address that I need to format correct.
Example in:
2620:0:2d0:200::7
2620:0:2d0:200:a0:c
2620:0a:3f0:200:a0:c
I need to convert them to:... (3 Replies)