aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTeddy Wing2016-09-10 21:33:29 -0400
committerTeddy Wing2016-09-10 21:33:29 -0400
commit3c620d853d73400fb61b9d431c4d7e041798a186 (patch)
tree66dfa6f8251150e8d43f5c7a10ce1b918f34bdb6
parent2626f20b298cbaa163eb4674f46bcc3808898789 (diff)
downloadirssi-slack-profile-3c620d853d73400fb61b9d431c4d7e041798a186.tar.bz2
swhois: Print additional profile information
Include full name, title, email, phone number, and skype name.
-rw-r--r--slack-profile.pl15
1 files changed, 14 insertions, 1 deletions
diff --git a/slack-profile.pl b/slack-profile.pl
index cd23035..6ad8452 100644
--- a/slack-profile.pl
+++ b/slack-profile.pl
@@ -73,7 +73,20 @@ sub swhois {
$data =~ s/^@//;
if (my $user = find_user($data)) {
- Irssi::print($user->{'real_name'});
+ Irssi::print($user->{'name'});
+ Irssi::print(' name : ' . $user->{'real_name'});
+ Irssi::print(' title : ' . $user->{'profile'}->{'title'});
+ Irssi::print(' email : ' . $user->{'profile'}->{'email'});
+
+ if ($user->{'profile'}->{'phone'}) {
+ Irssi::print(' phone : ' . $user->{'profile'}->{'phone'});
+ }
+
+ if ($user->{'profile'}->{'skype'}) {
+ Irssi::print(' skype : ' . $user->{'profile'}->{'skype'});
+ }
+
+ Irssi::print('End of SWHOIS');
}
}
else {