From: Dietmar Maurer Date: Tue, 5 Jun 2018 10:06:31 +0000 (+0200) Subject: Remove the File::HomeDir requirement X-Git-Url: https://git.proxmox.com/?p=pve-client.git;a=commitdiff_plain;h=aa5833d6e7953bf75a48c242fdce43059ed168ea Remove the File::HomeDir requirement Simply use $ENV{HOME} instead. --- diff --git a/PVE/APIClient/Config.pm b/PVE/APIClient/Config.pm index 8a77848..65c555f 100644 --- a/PVE/APIClient/Config.pm +++ b/PVE/APIClient/Config.pm @@ -4,7 +4,6 @@ use strict; use warnings; use JSON; -use File::HomeDir (); use PVE::JSONSchema qw(register_standard_option get_standard_option); use PVE::SectionConfig; use PVE::Tools qw(file_get_contents file_set_contents); @@ -90,7 +89,11 @@ sub private { sub config_filename { my ($class) = @_; - return File::HomeDir::home() . '/.pveclient'; + my $home = $ENV{HOME}; + + die "environment HOME not set\n" if !defined($home); + + return "$home/.pveclient"; } sub load {