Result:
found 1037 distributions and 1810 files matching your query ! ( run in 0.591 )


Plack-App-MCCS

 view release on metacpan or  search on metacpan

local/lib/perl5/ExtUtils/Helpers/Unix.pm  view on Meta::CPAN


sub detildefy {
	my $value = shift;
	# tilde with optional username
	for ($value) {
		s{ ^ ~ (?= /|$)}          [ $ENV{HOME} || (getpwuid $>)[7] ]ex or # tilde without user name
		s{ ^ ~ ([^/]+) (?= /|$) } { (getpwnam $1)[7] || "~$1" }ex;        # tilde with user name
	}
	return $value;
}

 view all matches for this distribution


Plack-App-dbi2http

 view release on metacpan or  search on metacpan

share/www/dbi2http.psgi  view on Meta::CPAN

use Plack::Builder;
use Plack::Util::PeriAHS qw(errpage);
use YAML::Syck ();

my $confpath = $ENV{DBI2HTTP_CONFIG_PATH} // do {
    my $home = (getpwuid($>))[7];  # $ENV{HOME} is empty if via fcgi
    "$home/dbi2http.conf.yaml";
};
my $conf = YAML::Syck::LoadFile($confpath);

my $fwr = File::Write::Rotate->new(

 view all matches for this distribution


Plate

 view release on metacpan or  search on metacpan

ppport.h  view on Meta::CPAN

GETPWENT_R_PROTO|5.008000|5.008000|Vn
getpwnam|5.009000||Viu
GETPWNAM_R_HAS_BUFFER|5.008000||Viu
GETPWNAM_R_HAS_PTR|5.008000||Viu
GETPWNAM_R_PROTO|5.008000|5.008000|Vn
getpwuid|5.009000||Viu
GETPWUID_R_HAS_PTR|5.008000||Viu
GETPWUID_R_PROTO|5.008000|5.008000|Vn
get_quantifier_value|5.033006||Viu
get_re_arg|||xciu
get_re_gclass_nonbitmap_data|5.031011||Viu

ppport.h  view on Meta::CPAN

KEY_getprotobyname|5.003007||Viu
KEY_getprotobynumber|5.003007||Viu
KEY_getprotoent|5.003007||Viu
KEY_getpwent|5.003007||Viu
KEY_getpwnam|5.003007||Viu
KEY_getpwuid|5.003007||Viu
KEY_getservbyname|5.003007||Viu
KEY_getservbyport|5.003007||Viu
KEY_getservent|5.003007||Viu
KEY_getsockname|5.003007||Viu
KEY_getsockopt|5.003007||Viu

 view all matches for this distribution


Pod-Minicpandoc

 view release on metacpan or  search on metacpan

Pod-Minicpandoc-0.16/Pod-Minicpandoc-0.16/lib/Pod/Minicpandoc.pm  view on Meta::CPAN

}

sub use_minicpan {
    my ( $self ) = @_;

    my $rc_file = File::Spec->catfile((getpwuid $<)[7], '.minicpanrc');
    return -e $rc_file;
}

sub get_minicpan_path {
    my ( $self ) = @_;

    my $rc_file = File::Spec->catfile((getpwuid $<)[7], '.minicpanrc');
    my $minicpan_path;

    my $fh;
    unless(open $fh, '<', $rc_file) {
        $self->aside("Unable to open '$rc_file': $!");

 view all matches for this distribution


Pod-Perldoc

 view release on metacpan or  search on metacpan

corpus/perlfunc.pod  view on Meta::CPAN

=item Fetching user and group info
X<user> X<group> X<password> X<uid> X<gid>  X<passwd> X</etc/passwd>

C<endgrent>, C<endhostent>, C<endnetent>, C<endpwent>, C<getgrent>,
C<getgrgid>, C<getgrnam>, C<getlogin>, C<getpwent>, C<getpwnam>,
C<getpwuid>, C<setgrent>, C<setpwent>

=item Fetching network info
X<network> X<protocol> X<host> X<hostname> X<IP> X<address> X<service>

C<endprotoent>, C<endservent>, C<gethostbyaddr>, C<gethostbyname>,

corpus/perlfunc.pod  view on Meta::CPAN

C<dbmclose>, C<dbmopen>, C<dump>, C<endgrent>, C<endhostent>,
C<endnetent>, C<endprotoent>, C<endpwent>, C<endservent>, C<exec>,
C<fcntl>, C<flock>, C<fork>, C<getgrent>, C<getgrgid>, C<gethostbyname>,
C<gethostent>, C<getlogin>, C<getnetbyaddr>, C<getnetbyname>, C<getnetent>,
C<getppid>, C<getpgrp>, C<getpriority>, C<getprotobynumber>,
C<getprotoent>, C<getpwent>, C<getpwnam>, C<getpwuid>,
C<getservbyport>, C<getservent>, C<getsockopt>, C<glob>, C<ioctl>,
C<kill>, C<link>, C<lstat>, C<msgctl>, C<msgget>, C<msgrcv>,
C<msgsnd>, C<open>, C<pipe>, C<readlink>, C<rename>, C<select>, C<semctl>,
C<semget>, C<semop>, C<setgrent>, C<sethostent>, C<setnetent>,
C<setpgrp>, C<setpriority>, C<setprotoent>, C<setpwent>,

corpus/perlfunc.pod  view on Meta::CPAN

restrict what salts C<crypt()> accepts.

Here's an example that makes sure that whoever runs this program knows
their password:

    $pwd = (getpwuid($<))[1];

    system "stty -echo";
    print "Password: ";
    chomp($word = <STDIN>);
    print "\n";

corpus/perlfunc.pod  view on Meta::CPAN

=item getlogin
X<getlogin> X<login>

This implements the C library function of the same name, which on most
systems returns the current login from F</etc/utmp>, if any.  If it
returns the empty string, use C<getpwuid>.

    $login = getlogin || getpwuid($<) || "Kilroy";

Do not consider C<getlogin> for authentication: it is not as
secure as C<getpwuid>.

Portability issues: L<perlport/getlogin>.

=item getpeername SOCKET
X<getpeername> X<peer>

corpus/perlfunc.pod  view on Meta::CPAN


Portability issues: L<perlport/getpriority>.

=item getpwnam NAME
X<getpwnam> X<getgrnam> X<gethostbyname> X<getnetbyname> X<getprotobyname>
X<getpwuid> X<getgrgid> X<getservbyname> X<gethostbyaddr> X<getnetbyaddr>
X<getprotobynumber> X<getservbyport> X<getpwent> X<getgrent> X<gethostent>
X<getnetent> X<getprotoent> X<getservent> X<setpwent> X<setgrent> X<sethostent>
X<setnetent> X<setprotoent> X<setservent> X<endpwent> X<endgrent> X<endhostent>
X<endnetent> X<endprotoent> X<endservent> 

corpus/perlfunc.pod  view on Meta::CPAN


=item getnetbyname NAME

=item getprotobyname NAME

=item getpwuid UID

=item getgrgid GID

=item getservbyname NAME,PROTO

corpus/perlfunc.pod  view on Meta::CPAN

In scalar context, you get the name, unless the function was a
lookup by name, in which case you get the other thing, whatever it is.
(If the entry doesn't exist you get the undefined value.)  For example:

    $uid   = getpwnam($name);
    $name  = getpwuid($num);
    $name  = getpwent();
    $gid   = getgrnam($name);
    $name  = getgrgid($num);
    $name  = getgrent();
    #etc.

 view all matches for this distribution


Pod-Simple-XHTML-BlendedCode

 view release on metacpan or  search on metacpan

inc/inc_Module-Build/Module/Build/Platform/Unix.pm  view on Meta::CPAN

sub _detildefy {
  my ($self, $value) = @_;
  $value =~ s[^~([^/]+)?(?=/|$)]   # tilde with optional username
    [$1 ?
     ((getpwnam $1)[7] || "~$1") :
     ($ENV{HOME} || (getpwuid $>)[7])
    ]ex;
  return $value;
}

1;

 view all matches for this distribution


Pod-Simple

 view release on metacpan or  search on metacpan

t/perlfaq.pod  view on Meta::CPAN


    # make file a month younger than today, defeating reaper daemons
    perl -e '$X=24*60*60; utime(time(),time() + 30 * $X,@ARGV)' *

    # find first unused uid
    perl -le '$i++ while getpwuid($i); print $i'

    # display reasonable manpath
    echo $PATH | perl -nl -072 -e '
	s![^/+]*$!man!&&-d&&!$s{$_}++&&push@m,$_;END{print"@m"}'

 view all matches for this distribution


Pod-Simpler-Aoh

 view release on metacpan or  search on metacpan

t/data/perlfaq.pod  view on Meta::CPAN


    # make file a month younger than today, defeating reaper daemons
    perl -e '$X=24*60*60; utime(time(),time() + 30 * $X,@ARGV)' *

    # find first unused uid
    perl -le '$i++ while getpwuid($i); print $i'

    # display reasonable manpath
    echo $PATH | perl -nl -072 -e '
	s![^/+]*$!man!&&-d&&!$s{$_}++&&push@m,$_;END{print"@m"}'

 view all matches for this distribution


Pod-Spell

 view release on metacpan or  search on metacpan

share/wordlist  view on Meta::CPAN

getprotobyname
getprotobynumber
getprotoent
getpwent
getpwnam
getpwuid
getservbyname
getservbyport
getservent
getsockname
gettimeofday

 view all matches for this distribution


PostScript-File

 view release on metacpan or  search on metacpan

lib/PostScript/File.pm  view on Meta::CPAN

    if ($o->{eps}) {
        $postscript .= $o->_bbox_comment('', $o->{bbox});
    }
    if ($o->{headings}) {
        require Sys::Hostname;
        my $user = getlogin() || (getpwuid($<))[0] || "Unknown";
        my $hostname = Sys::Hostname::hostname();
        $postscript .= $o->_here_doc(<<END_TITLES);
        \%\%For: $user\@$hostname
        \%\%Creator: Perl module ${\( ref $o )} v$PostScript::File::VERSION
        \%\%CreationDate: ${\( scalar localtime )}

lib/PostScript/File.pm  view on Meta::CPAN



sub check_tilde ($) { ## no critic (ProhibitSubroutinePrototypes)
    my ($dir) = @_;
    $dir = "" unless defined $dir;
    $dir =~ s{^~([^/]*)}{$1 ? (getpwnam($1))[7] : ($ENV{HOME} || $ENV{LOGDIR} || (getpwuid($>))[7]) }ex;
    return $dir;
}


sub array_as_string (@) { ## no critic (ProhibitSubroutinePrototypes)

lib/PostScript/File.pm  view on Meta::CPAN

  %%For: USER@HOSTNAME
  %%Creator: Perl module PostScript::File v2.23
  %%CreationDate: Sun Jan  1 00:00:00 2012
  %%DocumentMedia: US-Letter 612 792 80 ( ) ( )

USER comes from C<getlogin() || getpwuid($<)>, and HOSTNAME comes from
L<Sys::Hostname>.  The DocumentMedia values come from the
L<paper size attributes|/"Paper Size and Margins">.  The
DocumentMedia comment is omitted from EPS files.

If you want different values, leave C<headings> false and use

 view all matches for this distribution


Prima

 view release on metacpan or  search on metacpan

Prima/Edit.pm  view on Meta::CPAN

delete die do dump each endgrent endhostent endnetent endprotoent endpwent
endservent eof eval exec exists exit exp fcntl fileno flock for fork format
formline getc getgrent getgrgid getgrnam gethostbyaddr gethostbyname gethostent
getlogin getnetbyaddr getnetbyname getnetent getpeername getpgrp getppid
getpriority getprotobyname getprotobynumber getprotoent getpwent getpwnam
getpwuid getservbyname getservbyport getservent getsockname getsockopt glob
gmtime goto grep hex if import index int ioctl join keys kill last lc lcfirst
length link listen local localtime log lstat m map mkdir msgctl msgget msgrcv
msgsnd my next no oct open opendir ord our pack package pipe pop pos print
printf prototype push q qq qr quotemeta qw qx rand read readdir readline
readlink readpipe recv redo ref rename require reset return reverse rewinddir

 view all matches for this distribution


Proc-ProcessTable-Colorizer

 view release on metacpan or  search on metacpan

lib/Proc/ProcessTable/Colorizer.pm  view on Meta::CPAN

			}

			#check to see if it needs to search for users
			my $user_search_array=$self->userSearchGet;
			if ( defined( $user_search_array->[0] ) ){
				my $user=getpwuid($proc->{uid});
				$required_hits++;
				my $user_search_int=0;
				my $matched=0;
				#search while we have a user defined and it has not already been matched
				while( 

lib/Proc/ProcessTable/Colorizer.pm  view on Meta::CPAN


					if (
						( $field eq 'uid' ) &&
						$self->{resolveUser}
						){
						$item=getpwuid($item);
					}

					#colorizes it
					if ( $field eq 'time' ){
						if ( $^O =~ 'linux' ){

 view all matches for this distribution


Proc-ProcessTable-ncps

 view release on metacpan or  search on metacpan

lib/Proc/ProcessTable/ncps.pm  view on Meta::CPAN

		my @new_line;

		#
		# handle username column
		#
		my $user=getpwuid($proc->{uid});
		if ( ! defined( $user ) ) {
			$user=$proc->{uid};
		}
		$user=color($self->nextColor).$user.color('reset');
		push( @new_line, $user );

 view all matches for this distribution


Proc-ProcessTable-piddler

 view release on metacpan or  search on metacpan

lib/Proc/ProcessTable/piddler.pm  view on Meta::CPAN

					  ]);

		#
		# UID
		#
		my $user=getpwuid($proc->{uid});
		if ( ! defined( $user ) ) {
			$user=color( $self->{idColors}[0] ).$proc->{uid}.color('reset');
		}else{
			$user=color( $self->{idColors}[0] ).$user.
			color( $self->{idColors}[1] ).'('.

 view all matches for this distribution


Proc-ProcessTable

 view release on metacpan or  search on metacpan

os/MSWin32.c  view on Meta::CPAN

	}

        {
          struct passwd *pw;

          if ((pw = getpwuid (p->version >= EXTERNAL_PINFO_VERSION_32_BIT ?
	                      p->uid32 : p->uid)))
            strcpy (uname, pw->pw_name);
          else
            sprintf (uname, "%u", (unsigned)
	             (p->version >= EXTERNAL_PINFO_VERSION_32_BIT ?

 view all matches for this distribution


Project-Easy

 view release on metacpan or  search on metacpan

lib/Project/Easy/Helper.pm  view on Meta::CPAN

	my $project_pm = Project::Easy::Config::string_from_template (
		$data_files->{'Project.pm'},
		$data
	);

	my $login = eval {scalar getpwuid ($<)};

	my $instance = 'local' . (defined $login ? ".$login" : '');
	
	my $root = dir->current;
	

 view all matches for this distribution


Promise-XS

 view release on metacpan or  search on metacpan

easyxs/ppport.h  view on Meta::CPAN

GETPWENT_R_PROTO|5.008000|5.008000|Vn
getpwnam|5.009000||Viu
GETPWNAM_R_HAS_BUFFER|5.008000||Viu
GETPWNAM_R_HAS_PTR|5.008000||Viu
GETPWNAM_R_PROTO|5.008000|5.008000|Vn
getpwuid|5.009000||Viu
GETPWUID_R_HAS_PTR|5.008000||Viu
GETPWUID_R_PROTO|5.008000|5.008000|Vn
get_quantifier_value|5.033006||Viu
get_re_arg|||xciu
get_re_gclass_nonbitmap_data|5.031011||Viu

easyxs/ppport.h  view on Meta::CPAN

KEY_getprotobyname|5.003007||Viu
KEY_getprotobynumber|5.003007||Viu
KEY_getprotoent|5.003007||Viu
KEY_getpwent|5.003007||Viu
KEY_getpwnam|5.003007||Viu
KEY_getpwuid|5.003007||Viu
KEY_getservbyname|5.003007||Viu
KEY_getservbyport|5.003007||Viu
KEY_getservent|5.003007||Viu
KEY_getsockname|5.003007||Viu
KEY_getsockopt|5.003007||Viu

 view all matches for this distribution


Prophet

 view release on metacpan or  search on metacpan

lib/Prophet/CLI/Command/Shell.pm  view on Meta::CPAN

        return $term;
    },
);

our $HIST = $ENV{PROPHET_HISTFILE}
  || ( ( $ENV{HOME} || ( getpwuid($<) )[7] ) . "/.prophetreplhist" );
our $LEN = $ENV{PROPHET_HISTLEN} || 500;

sub usage_msg {
    my $self = shift;
    my $cmd  = $self->cli->get_script_name;

 view all matches for this distribution


Protocol-DBus

 view release on metacpan or  search on metacpan

lib/Protocol/DBus/Authn/Mechanism/DBUS_COOKIE_SHA1.pm  view on Meta::CPAN

}

sub _getpw {
    my ($self) = @_;

    $self->{'_pw'} ||= [ getpwuid $> ];

    return @{ $self->{'_pw'} };
}

sub _consume_data {

 view all matches for this distribution


Protocol-Redis-XS

 view release on metacpan or  search on metacpan

ppport.h  view on Meta::CPAN

GETPWENT_R_PROTO|5.008000|5.008000|Vn
getpwnam|5.009000||Viu
GETPWNAM_R_HAS_BUFFER|5.008000||Viu
GETPWNAM_R_HAS_PTR|5.008000||Viu
GETPWNAM_R_PROTO|5.008000|5.008000|Vn
getpwuid|5.009000||Viu
GETPWUID_R_HAS_PTR|5.008000||Viu
GETPWUID_R_PROTO|5.008000|5.008000|Vn
get_quantifier_value|5.033006||Viu
get_re_arg|||xciu
get_re_gclass_nonbitmap_data|5.031011||Viu

ppport.h  view on Meta::CPAN

KEY_getprotobyname|5.003007||Viu
KEY_getprotobynumber|5.003007||Viu
KEY_getprotoent|5.003007||Viu
KEY_getpwent|5.003007||Viu
KEY_getpwnam|5.003007||Viu
KEY_getpwuid|5.003007||Viu
KEY_getservbyname|5.003007||Viu
KEY_getservbyport|5.003007||Viu
KEY_getservent|5.003007||Viu
KEY_getsockname|5.003007||Viu
KEY_getsockopt|5.003007||Viu

 view all matches for this distribution


Provision-Unix

 view release on metacpan or  search on metacpan

lib/Provision/Unix/Utility.pm  view on Meta::CPAN


    my %args = ( debug => $p{debug}, fatal => $p{fatal} );

    -e $file or return $log->error( "$file does not exist.", %args);
    -r $file or return $log->error( "$file is not readable by you ("
            . getpwuid($>)
            . "). You need to fix this, using chown or chmod.", %args);

    return 1;
}

lib/Provision/Unix/Utility.pm  view on Meta::CPAN

    if ( !-e $file ) {

        my ( $base, $path, $suffix ) = fileparse($file);

        return $log->error( "is_writable: $path not writable by "
            . getpwuid($>)
            . "$nl$nl", %args) if (-e $path && !-w $path);
        return 1;
    }

    return $log->error( "  $file not writable by " . getpwuid($>) . "$nl$nl", %args ) if ! -w $file;

    $log->audit( "$file is writable" );
    return 1;
}

 view all matches for this distribution


Prty

 view release on metacpan or  search on metacpan

lib/Prty/System.pm  view on Meta::CPAN

# -----------------------------------------------------------------------------

sub user {
    my ($this,$uid) = @_;

    return getpwuid($uid) // do {
        $this->throw(
            q~SYS-00001: Benutzer existiert nicht~,
            Uid=>$uid,
            Error=>"$!",
        );

 view all matches for this distribution


QBit-Cron

 view release on metacpan or  search on metacpan

lib/QBit/Cron.pm  view on Meta::CPAN

    my $cron_cmd = 'perl'
      . (exists($opts{'framework_path'})   ? " -I$opts{'framework_path'}"   : '')
      . (exists($opts{'application_path'}) ? " -I$opts{'application_path'}" : '')
      . " -M$cron_pkg -e'$cron_pkg->new->do'";

    my ($cur_user) = getpwuid($<);
    my $user = $opts{'user'} || $cur_user;
    foreach my $path (sort keys(%$methods)) {
        foreach my $method (sort keys(%{$methods->{$path}})) {
            print join("\t", $methods->{$path}{$method}{'time'}, $user, "$cron_cmd $path $method") . "\n\n";
        }

 view all matches for this distribution


Queue-Q4M

 view release on metacpan or  search on metacpan

misc/lib/Queue/Q4M/Benchmark.pm  view on Meta::CPAN


has 'username' => (
    is => 'rw',
    isa => 'Str',
    required => 1,
    default => sub { (getpwuid($>))[0] },
    trigger => sub { $_[0]->connect_info->[1] = $_[1] }
);

has 'password' => (
    is => 'rw',

 view all matches for this distribution


Quiq

 view release on metacpan or  search on metacpan

lib/Quiq/System.pm  view on Meta::CPAN


sub user {
    my $this = shift;
    my $uid = shift // $>;

    return getpwuid($uid) // do {
        $this->throw(
            'SYS-00001: Benutzer existiert nicht',
            Uid => $uid,
            Error => "$!",
        );

 view all matches for this distribution


Quizzer

 view release on metacpan or  search on metacpan

exercises/compile-tcsh/tcsh-6.10.00/sh.c  view on Meta::CPAN

	cus = getenv("USER");
	if (cus != NULL)
	    set(STRuser, quote(SAVE(cus)), VAR_READWRITE);
	else if (cln != NULL)
	    set(STRuser, quote(SAVE(cln)), VAR_READWRITE);
	else if ((pw = getpwuid(uid)) == NULL)
	    set(STRuser, SAVE("unknown"), VAR_READWRITE);
	else
	    set(STRuser, SAVE(pw->pw_name), VAR_READWRITE);
	if (cln == NULL)
	    tsetenv(STRLOGNAME, varval(STRuser));

 view all matches for this distribution


Quota-OO

 view release on metacpan or  search on metacpan

lib/Quota/OO.pm  view on Meta::CPAN

    }

    sub set_gid {
        my ($self, $gid) = @_;
        $gid{ ident $self } 
            = $gid =~ m{^\d+$} ? $gid : ( getpwuid($uid{ ident $self }) )[3];	
    }

#### do rcp* ##
#### Quota::rpcquery ##
	sub rpcquery {

 view all matches for this distribution


RDF-Crypt

 view release on metacpan or  search on metacpan

lib/RDF/Crypt/Role/DoesEncrypt.pm  view on Meta::CPAN

	
	my $crypto = $self->encrypt_model($model, %{ $rdfopts || +{} });
	my $default_from =
		   $RDF::Crypt::SENDER
		|| $ENV{EMAIL_ADDRESS}
		|| ((getlogin||getpwuid($<)||"anonymous").'@'.Sys::Hostname::hostname);

	my %headers = %{ $mailopts->{headers} || +{} };

	my $msg = Mail::Message->build(
		To            => $results[0],

 view all matches for this distribution


RPC-Serialized

 view release on metacpan or  search on metacpan

lib/RPC/Serialized.pm  view on Meta::CPAN

# 
# The C<UCSPI/IPC> server will look for the C<IPCREMOTEINFO> environment
# variable, if authorization is enabled. See the <ucspi-ipc> documentation for
# details if you don't know how to enable this.
# 
# =item C<getpwuid $uid failed> in an C<X::Authorization>
# 
# The C<UCSPI/IPC> server failed to get the username for the calling user. Only
# happens if authorization has been enabled.
# 
# =item C<Not a RPC::Serialized::AuthzHandler> in an C<X::Application>

 view all matches for this distribution


RPM-Specfile

 view release on metacpan or  search on metacpan

cpanflute2  view on Meta::CPAN

$defaults{'outdir'}  = './';
$defaults{'tmpdir'}  = '/tmp';
$defaults{'release'} = '8';
$defaults{'installdirs'} = "";
{
  my ($username, $fullname) = (getpwuid($<))[0,6];
  $fullname = (split /,/, $fullname)[0];
  $defaults{'email'}  = $fullname ? $fullname . ' ' : '';
  $defaults{'email'} .= '<';
  $defaults{'email'} .= $ENV{REPLYTO} || $username . '@redhat.com';
  $defaults{'email'} .= '>';

 view all matches for this distribution


( run in 0.591 second using v1.01-cache-2.11-cpan-47059a37de6 )