diff --git a/docs/faq.html b/docs/faq.html index 7c17f45d..50b404a0 100644 --- a/docs/faq.html +++ b/docs/faq.html @@ -2,7 +2,7 @@
A: They force ANSI colors even if terminal doesn’t support them. By default, irssi uses colors only if terminfo/termcap so says. The correct way to fix this would be to change your TERM environment to a value where colors work, like xterm-color or color_xterm (eg. TERM=xterm-color irssi
). If this doesn’t help, then use the evil way of /SET term_force_colors ON
.
A: They force ANSI colors even if terminal doesn’t support them. By default, irssi uses colors only if terminfo/termcap so says. The correct way to fix this would be to change your TERM environment to a value where colors work, like xterm-256color or color_xterm (eg. TERM=xterm-256color irssi
). If this doesn’t help, then use the evil way of /SET term_force_colors ON
.
A: tmux, screen and dtach can be used to do it just fine.
+A: tmux, screen and dtach can be used to do it just fine.
And finally channels:
-/CHANNEL ADD -auto -bots *!*user@host -botcmd "/^msg $0 op pass" #irssi efnet
+/CHANNEL ADD -auto -bots *!*bot@host.org -botcmd "/^msg $0 op pass" #irssi efnet
/CHANNEL ADD -auto #secret IRCnet password
@@ -395,7 +395,7 @@ Ctrl-X - set the next server in list active
/HELP bind
tells pretty much everything there is to know about keyboard bindings. However, there’s the problem of how to bind some non-standard keys. They might differ a bit with each terminal, so you’ll need to find out what exactly the keypress produces. Easiest way to check that would be to see what it prints in cat
. Here’s an example for pressing F1 key:
- [user@host] ~% cat
+ [cras@hurina] ~% cat
^[OP
diff --git a/docs/startup-HOWTO.txt b/docs/startup-HOWTO.txt
index bff33108..90d278de 100644
--- a/docs/startup-HOWTO.txt
+++ b/docs/startup-HOWTO.txt
@@ -218,7 +218,7 @@ IRC network, other servers are automatically connected in same network if the
And finally channels:
-/CHANNEL ADD -auto -bots *!*user@host -botcmd "/^msg $0 op pass" #irssi efnet
+/CHANNEL ADD -auto -bots *!*bot@host.org -botcmd "/^msg $0 op pass" #irssi efnet
/CHANNEL ADD -auto #secret IRCnet password
-bots and -botcmd should be the only ones needing a bit of explaining. They’re
@@ -442,7 +442,7 @@ They might differ a bit with each terminal, so you’ll need to find out what
exactly the keypress produces. Easiest way to check that would be to see what
it prints in cat. Here’s an example for pressing F1 key:
- [user@host] ~% cat
+ [cras@hurina] ~% cat
^[OP
So in irssi you would use /BIND ^[OP /ECHO F1 pressed. If you use multiple
diff --git a/scripts/quitmsg.pl b/scripts/quitmsg.pl
index e289468c..102d9aa5 100644
--- a/scripts/quitmsg.pl
+++ b/scripts/quitmsg.pl
@@ -6,36 +6,27 @@ use Irssi::Irc;
use strict;
use vars qw($VERSION %IRSSI);
-$VERSION = "1.00";
+$VERSION = "1.01";
%IRSSI = (
authors => 'Timo Sirainen',
name => 'quitmsg',
description => 'Random quit messages',
license => 'Public Domain',
- changed => 'Sun Mar 10 23:18 EET 2002'
+ changed => 'Mon Jul 22 20:00 EET 2020'
);
-my $quitfile = glob "~/.irssi/irssi.quit";
+my $quitfile = Irssi::get_irssi_dir() . "/irssi.quit";
sub cmd_quit {
my ($data, $server, $channel) = @_;
return if ($data ne "");
+
+ open (my $fh, "<", $quitfile) || return;
+ my @lines = <$fh>;
- open (f, "<", $quitfile) || return;
- my $lines = 0; while() { $lines++; };
-
- my $line = int(rand($lines))+1;
-
- my $quitmsg;
- seek(f, 0, 0); $. = 0;
- while() {
- next if ($. != $line);
-
- chomp;
- $quitmsg = $_;
- last;
- }
- close(f);
+ my $quitmsg = $lines[int(rand(@lines))];
+ chomp($quitmsg);
+ close($fh);
foreach my $server (Irssi::servers) {
$server->command("/disconnect ".$server->{tag}." $quitmsg");
diff --git a/scripts/scriptassist.pl b/scripts/scriptassist.pl
index 536ef33a..cf02d57e 100644
--- a/scripts/scriptassist.pl
+++ b/scripts/scriptassist.pl
@@ -5,7 +5,7 @@
use strict;
-our $VERSION = '2003020807';
+our $VERSION = '2020042700';
our %IRSSI = (
authors => 'Stefan \'tommie\' Tomanek',
contact => 'stefan@pico.ruhr.de',
@@ -23,12 +23,15 @@ use Irssi 20020324;
use CPAN::Meta::YAML;
use LWP::UserAgent;
use POSIX;
+use version;
# GnuPG is not always needed
$have_gpg = 0;
eval "use GnuPG qw(:algo :trust);";
$have_gpg = 1 if not ($@);
+my $irssi_version = qv(Irssi::parse_special('v$J') =~ s/-.*//r);
+
sub show_help {
my $help = "scriptassist $VERSION
/scriptassist check
@@ -39,15 +42,15 @@ sub show_help {
Search the script database
/scriptassist info
Display information about
-".#/scriptassist ratings
-# Retrieve the average ratings of the the scripts
-#/scriptassist top
-# Retrieve the first top rated scripts
-"/scriptassist new
+/scriptassist ratings
+ Retrieve the average ratings of the the scripts
+/scriptassist top
+ Retrieve the first top rated scripts
+/scriptassist new
Display the newest scripts
-".#/scriptassist rate