Bootstrap FreeKB - Perl (Scripting) - Home Directory
Perl (Scripting) - Home Directory

Updated:   |  Perl (Scripting) articles

File::HomeDir can be used to return a users home directory.

#!/usr/bin/perl
use strict;
use warnings;
use File::HomeDir;

my $home = File::HomeDir->my_home;

print "home directory = $home \n";

 

 




Did you find this article helpful?

If so, consider buying me a coffee over at Buy Me A Coffee



Comments


Add a Comment


Please enter 0d16c0 in the box below so that we can be sure you are a human.