when ever i am trying to get it to an array using FH, its making the output to ugly, i mean is there anyway i can make it looks good, as we are getting true value/output at command file, i mean apropriate space and lines. . . . sorry for making earlier description skeptical, actually i want some thing like, all line and column will contain exact value, likehere i am forwarding process status to a file "process", 'ps -ef >process'(this is done by a cron job at every day) here is part my perl code my $uxinfo = "process"; open(INFO, $uxinfo); @uinfo = <INFO>; foreach my $line (@uinfo) { chomp($line); next if ($line eq "" ); print "$line";}} }
but in the output all these things are messing up like following:#ps -ef UID PID PPID C STIME TTY TIME CMD root 1 0 0 2007 ? 00:00:02 init [3] root 2 1 0 2007 ? 00:01:34 [gration/0] root 3 1 0 2007 ? 00:00:01
i want exact value should be in exact column!! thanks to all for your quick feedbacks..UID PID PPID C STIME TTY TIME CMD root 1 0 0 2007 ? 00:00:02 init [3] root 2 1 0 2007 ? 00:01:34 [gration/0] root 3 1 0 2007 ? 00:00:01
In reply to Text format array by ashutoshinbox
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |