aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuillermo Ramos2024-03-14 18:26:52 +0100
committerGuillermo Ramos2024-03-14 18:26:52 +0100
commit4eccd6aafaf1df75efea97d90d9d6e88ca61452e (patch)
treea63ff5c01426e86e3a8608817db76a5d204fc729
parentbcd4636a8f1235ef9429599e04d294384572650e (diff)
downloadcli-4eccd6aafaf1df75efea97d90d9d6e88ca61452e.tar.gz
ssf: changes from TC
-rwxr-xr-xssf4
1 files changed, 3 insertions, 1 deletions
diff --git a/ssf b/ssf
index f10db57..dcd7322 100755
--- a/ssf
+++ b/ssf
@@ -44,7 +44,9 @@ foreach my $cfgfile (glob("$ENV{HOME}/.ssh/config.d/*"), "$ENV{HOME}/.ssh/config
}
my @hosts_no_wild = grep { not $_ =~ /\*/ } (map { $_->{_pat} } @hosts);
-my $newlined_hosts = join "\n", sort @hosts_no_wild;
+my %tmp = map { $_, 1 } @hosts_no_wild;
+my @hosts_no_rep = keys %tmp;
+my $newlined_hosts = join "\n", sort @hosts_no_rep;
my $fzf_cmd = 'fzf';
if (exists $ENV{TMUX}) {