Correct macro_hostname to be as per the docs

macro_hostname should be the FQDN of the server where cssh is being run
This commit is contained in:
Duncan Ferguson 2019-03-16 14:54:31 +00:00
parent dd33799eb7
commit 6529bccdbd
2 changed files with 4 additions and 1 deletions

View file

@ -3,6 +3,7 @@ Revision history for {{$dist->name}}
4.13.2_03 ????-??-?? Duncan Ferguson <duncan_ferguson@user.sf.net>
- Include README within the repository, not just created tar.gz files
- Add 'autoquit' setting to 'File' menu (Github issue #114)
- Correct macro_hostname to be the FQDN of the server where cssh is being run
4.13.2_02 2019-01-14 Duncan Ferguson <duncan_ferguson@user.sf.net>
- Fix Getopt-Long minimum version

View file

@ -10,6 +10,7 @@ use English qw( -no_match_vars );
use base qw/ App::ClusterSSH::Base /;
use vars qw/ %keysymtocode %keycodetosym /;
use Net::Domain qw(hostfqdn);
use File::Temp qw/:POSIX/;
use Fcntl;
use POSIX ":sys_wait_h";
@ -595,7 +596,8 @@ sub substitute_macros {
}
{
my $macro_hostname = $self->config->{macro_hostname};
my $hostname = $servers{$svr}{givenname};
#my $hostname = $servers{$svr}{givenname};
my $hostname = hostfqdn();
$text =~ s!$macro_hostname!$hostname!xsmg;
}
{