Result:
found 1012 distributions and 1781 files matching your query ! ( run in 0.707 )


Config-App

 view release on metacpan or  search on metacpan

lib/Config/App.pm  view on Meta::CPAN

        ( my $box = ( POSIX::uname )[1] ) =~ s/\..*$//;
        my $conf  = {};

        _process_location({
            box      => $box,
            user     => getpwuid($>) || POSIX::cuserid,
            env      => $ENV{CONFIGAPPENV},
            conf     => $conf,
            optional => 0,
            location => $location,
        });

 view all matches for this distribution


Config-Backend-SQL

 view release on metacpan or  search on metacpan

lib/Config/Backend/SQL.pm  view on Meta::CPAN

    $sth->finish();
  }

  # Get USER ID

  $self->{"user"}=getlogin() || getpwuid( $< ) || 
                  $ENV{ LOGNAME } || $ENV{ USER } ||
                  $ENV{ USERNAME } || 'unknown';

  # bless

 view all matches for this distribution


Config-Crontab

 view release on metacpan or  search on metacpan

example/crontab.cgi  view on Meta::CPAN

    ##############################################
    ##              New Raw Block               ##
    ##############################################
    elsif( $q->param('Block Raw New') ) {
	## display edit page and exit
	print $q->start_html("New crontab block for " . getpwuid($<)),
	  $q->strong('Add a new crontab entry:'), $q->p, "\n\n";
	print "<ul>" . $info . "</ul>" if $info;
	print $q->start_form;
	print $q->textarea( -name    => 'blocktext',
			    -default => '',

example/crontab.cgi  view on Meta::CPAN


    ##############################################
    ##             Raw Block Edit               ##
    ##############################################
    if( $q->param('Block Raw Edit') ) {
	print $q->start_html("Edit crontab block for " . getpwuid($<)),
	  $q->strong('Edit this block:'), $q->p, "\n\n";
	print "<ul>" . $info . "</ul>" if $info;
	print $q->start_form;
	print $q->hidden('blockno', $q->param('blockno'));
	print $q->textarea( -name    => 'blocktext',

example/crontab.cgi  view on Meta::CPAN

	## this will trigger if user deletes last line in a block, or the
	## block was emptied by someone else before we got here (no locking)
	last ACTION unless $block->lines;

	## display edit block page and exit
	print $q->start_html("Edit crontab block for " . getpwuid($<)),
	  $q->strong('Edit this block:'), "<br>\n";
	print "Date: " . scalar(localtime) . "<br>\n";
	print "<ul>" . $info . "</ul>" if $info;

	print $q->start_form;

example/crontab.cgi  view on Meta::CPAN


	exit;
    }
}

print $q->start_html("Crontab for " . getpwuid($<)),
  $q->strong('Edit your crontab:'), "<br>\n\n";
print "Date: " . scalar(localtime) . "<br>\n";
print "<ul><em>" . $info . "</em></ul>" if $info;

print $q->start_form;

 view all matches for this distribution


Config-Find

 view release on metacpan or  search on metacpan

lib/Config/Find/Unix.pm  view on Meta::CPAN


sub _my_home {
    my $home = File::HomeDir->my_home;
    return $home            if defined $home;

    my ($user, $dir) = (getpwuid $>)[0, 7];

    return $dir             if defined $dir;
    return "/home/$user"    if defined $user;
    return "/"
};

 view all matches for this distribution


Config-IOD-Reader

 view release on metacpan or  search on metacpan

lib/Config/IOD/Base.pm  view on Meta::CPAN

    if ($^O eq 'MSWin32') {
        return $ENV{USERNAME};
    } else {
        return $ENV{USER} if $ENV{USER};
        my @pw;
        eval { @pw = getpwuid($>) };
        return $pw[0] if @pw;
    }
}

# borrowed from PERLANCAR::File::HomeDir 0.04

lib/Config/IOD/Base.pm  view on Meta::CPAN

        return join($ENV{HOMEDRIVE}, "\\", $ENV{HOMEPATH})
            if $ENV{HOMEDRIVE} && $ENV{HOMEPATH};
    } else {
        return $ENV{HOME} if $ENV{HOME};
        my @pw;
        eval { @pw = getpwuid($>) };
        return $pw[7] if @pw;
    }

    die "Can't get home directory";
}

lib/Config/IOD/Base.pm  view on Meta::CPAN


    if ($^O eq 'MSWin32') {
        # not yet implemented
        return undef; ## no critic: Subroutines::ProhibitExplicitReturnUndef
    } else {
        # IF and only if we have getpwuid support, and the name of the user is
        # our own, shortcut to my_home. This is needed to handle HOME
        # environment settings.
        if ($name eq getpwuid($<)) {
            return _get_my_home_dir();
        }

      SCOPE: {
            my $home = (getpwnam($name))[7];

 view all matches for this distribution


Config-IOD

 view release on metacpan or  search on metacpan

t/encoding_path.t  view on Meta::CPAN

my $tempdir = tempdir(CLEANUP => 1);
_create_file("$tempdir/f1", "");
_create_file("$tempdir/f2", "");
_create_file("$tempdir/g1", "");

my @pw = getpwuid($>);

# the rest of the test is performed in Config-IOD-Reader dist

my $doc = Config::IOD->new->read_string(<<EOF);
[without_encoding]

 view all matches for this distribution


Connector

 view release on metacpan or  search on metacpan

t/01-builtin-file-path.t  view on Meta::CPAN


SKIP: {
    skip  "skipping chown test - set CONN_PATH_USER in ENV", 1 unless ( $ENV{CONN_PATH_USER} );
    $conn->user($ENV{CONN_PATH_USER} );
    $conn->set('testuser', 'wont see');
    is ($ENV{CONN_PATH_USER}, getpwuid(( stat "t/config/testuser.txt")[4]));
}

SKIP: {
    skip  "skipping chown test - set CONN_PATH_GROUP in ENV", 1 unless ( $ENV{CONN_PATH_GROUP} );
    $conn->group($ENV{CONN_PATH_GROUP} );

 view all matches for this distribution


Convert-Binary-C

 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


Convert-Pheno

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN


 - Modified t/args.t to make it 'MSWin32' and 'cygwin' compatible

0.11_3 2023-07-17T00:00:00Z (Manuel Rueda <mrueda@cpan.org>)

 - Changed getpwuid to $ENV{'USERNAME'} to make 'MSWin32' compatible

0.11_2 2023-07-10T00:00:00Z (Manuel Rueda <mrueda@cpan.org>)

 - Modified Python binding to work in Conda env
 - Increased Perl version from 5.16 to 5.26

 view all matches for this distribution


Convert-UUlib

 view release on metacpan or  search on metacpan

uulib/aclocal.m4  view on Meta::CPAN

AC_MSG_CHECKING(if we can use -lnsl)
ac_save_LIBS="$LIBS";
LIBS="$LIBS -lnsl";
AC_CACHE_VAL(r_cv_use_libnsl, [
AC_TRY_RUN(
main() { if (getpwuid(getuid())) exit(0); exit(-1); },
nc_cv_use_libnsl=yes, nc_cv_use_libnsl=no, nc_cv_use_libnsl=no)
])
if test "$nc_cv_use_libnsl" = "no"; then LIBS="$ac_save_LIBS"; fi
AC_MSG_RESULT($nc_cv_use_libnsl)
])dnl

 view all matches for this distribution


Crypt-Cracklib

 view release on metacpan or  search on metacpan

t/01use.t  view on Meta::CPAN

use Test::More tests => 22;

BEGIN { use_ok( 'Crypt::Cracklib' ); }

SKIP: {
    $username = getpwuid($<);
    skip "won't work unless username is longer", 1
    unless length($username) > 4;
    like(fascist_check($username.'1'), qr/username/, "username");
};

 view all matches for this distribution


Crypt-HSM

 view release on metacpan or  search on metacpan

lib/Crypt/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

lib/Crypt/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


Crypt-License

 view release on metacpan or  search on metacpan

License.pm  view on Meta::CPAN


my ($user,$grp,$pwd);

$user_info = sub {
  ($pwd) = @_;
  $user = (getpwuid( (stat($pwd))[4] ))[0];
  $grp = (getgrgid( (stat($pwd))[5] ))[0];
  my $i;
  if ( $pwd !~ m|^/| ) {
    $i = `/bin/pwd`;
    $i =~ s/\s+//g;

 view all matches for this distribution


Crypt-MatrixSSL3

 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


Crypt-OpenSSL-AES

 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


Crypt-OpenSSL-Blowfish

 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


Crypt-OpenSSL-ConfiguredAPI

 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


Crypt-OpenSSL-PKCS10

 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


Crypt-OpenSSL-PKCS12

 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


Crypt-OpenSSL-SignCSR

 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


Crypt-OpenSSL-X509

 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_re_arg|||xciu
get_re_gclass_nonbitmap_data|5.031010||Viu
get_regclass_nonbitmap_data|5.031010||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


CryptX

 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


Curses-UI-POE

 view release on metacpan or  search on metacpan

examples/pop3_reader  view on Meta::CPAN

	);

	$conwin->add(
		'username', 'TextEntry',
		-x => 14, -y => 4,
		-text => getpwuid($>),
	);

	$conwin->add(
		'password_label', 'Label',	
		-x => 0, -y => 6, -width => 13,

 view all matches for this distribution


Curses-UI

 view release on metacpan or  search on metacpan

lib/Curses/UI/Dialog/Dirbrowser.pm  view on Meta::CPAN

# Set $this->{-path} to the homedirectory of the current user.
sub goto_homedirectory()
{
    my $this = shift;

    my @pw = getpwuid($>);
    if (@pw) {
        if (-d $pw[7]) {
	    $this->{-path} = $pw[7];
        } else {
	    $this->{-path} = '/';

 view all matches for this distribution


Cyrillic

 view release on metacpan or  search on metacpan

lib/Ecyrillic.pm  view on Meta::CPAN


    ### More-desperate methods

    # Light desperation on any (Unixish) platform
    else {
        $home = CORE::eval q{ (getpwuid($<))[7] };
    }

    # On Unix in general, a non-existant home means "no home"
    # For example, "nobody"-like users might use /nonexistant
    if (defined $home and ! -d($home)) {

 view all matches for this distribution


DAT-TimTen

 view release on metacpan or  search on metacpan

t/DAT-TimTen.t  view on Meta::CPAN

# ensure subprocess (for pipeone and stream transport) will use the same modules as us, ie ./blib
local $ENV{PERL5LIB} = join $Config{path_sep}, @INC;

my %durations;
my $getcwd = getcwd();
my $username = eval { getpwuid($>) } || ''; # fails on windows
my $can_ssh = ($username && $username eq 'timbo' && -d '.svn'
            && system("sh -c 'echo > /dev/tcp/localhost/22' 2>/dev/null")==0
);
my $perl = "$^X  -Mblib=$getcwd/blib"; # ensure sameperl and our blib (note two spaces)

 view all matches for this distribution


DB-Ent

 view release on metacpan or  search on metacpan

Ent.pm  view on Meta::CPAN

    my $self = shift;
    %$self = (%$self, @_);

    $self->{proto} ||= "mysql";
    $self->{srv}   ||= "localhost";
    $self->{usr}   ||= (getpwuid($>))[0];
    $self->{pwd}   ||= "";
    $self->{dbn}   ||= "";

    my $dsn = join ":", "DBI", @{$self}{qw/proto dbn srv/};
    $self->{dbh} = DBI->connect($dsn, $self->{usr}, $self->{pwd});

 view all matches for this distribution


DB-Object

 view release on metacpan or  search on metacpan

lib/DB/Object/Postgres.pm  view on Meta::CPAN

sub _check_connect_param
{
    my $self  = shift( @_ );
    my $param = $self->SUPER::_check_connect_param( @_ ) || return( $self->pass_error );
    # This is also what the psql command line tool does
    $param->{login} = ( getpwuid( $> ) )[0] if( !$param->{login} );
    $param->{database} = 'postgres' if( !$param->{database} );
    # By default
    $param->{port} = 5432 if( !length( $param->{port} ) );
    return( $param );
}

 view all matches for this distribution


DB2-Admin

 view release on metacpan or  search on metacpan

t/50force.t  view on Meta::CPAN


$snap = DB2::Admin->GetSnapshot('Subject' => 'SQLMA_APPL_ALL');
ok ($snap, "Application snapshot (before)");

my $agent_id;
my $username = ($^O =~ /^MSWin / ? $ENV{USERNAME} : getpwuid($<));
foreach my $node ($snap->findNodes('APPL')) {
    my $dbname = $node->findValue('APPL_INFO/DB_NAME');
    $dbname =~ s/\s+$//;
    next unless (lc $dbname eq lc $test_db);

 view all matches for this distribution


DBD-CSV

 view release on metacpan or  search on metacpan

t/71_csv-ext.t  view on Meta::CPAN

my $dbh;
my @ext = ("", ".csv", ".foo", ".txt");

sub DbFile;

my $usr = eval { getpwuid $< } || $ENV{USERNAME} || "";
sub Tables {
    my @tbl = $dbh->tables ();
    if ($usr) {
	s/^['"]*$usr["']*\.//i for @tbl;
	}

 view all matches for this distribution


( run in 0.707 second using v1.01-cache-2.11-cpan-8d75d55dd25 )