#!/usr/bin/perl -w # prints environment variables for suggested process # written by dpecka[at]techniservit.cz use strict; die "you need pass pid of wanted proccess as parameter\n" if not @ARGV; my($foo, @FOO); $foo = "@ARGV"; die "it does not seem like pid number\n" if $foo !~ /^\d $/; chomp(@FOO = `pargs -e $foo 2>/dev/null`); die "can't find process with pid $foo\n" if $? != '0'; foreach (@FOO) { s/^.[^:]*:\s //g; print "$_\n"; };