whoami implementation

[email protected] Wed, 4 Oct 2006 09:47:11 -0700
Newsgroups perl.ppt
Message-ID <[email protected]>
#!/usr/bin/perl
# whoami for PPT
# Public domain.
# by David Koenig.

print getpwuid($>)."\n";

__END__

=head1 NAME

whoami - display effective user ID

=head1 SYNOPSIS

whoami

=head1 DESCRIPTION

The I<whoami> utility is obsolite.  Use I<id -un>.

This utility simply returns the effective user ID.

=head1 SEE ALSO

L<id(1)>

=head1 AUTHOR

David Koenig <[email protected]>.

=head1 COPYRIGHT

This page, as well as the implementation of the utility, are public domain.