summaryrefslogtreecommitdiff
path: root/.irssi
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2015-10-27 02:42:09 +0000
committerSean Whitton <spwhitton@spwhitton.name>2015-10-27 02:42:09 +0000
commitfda0464cbab8590f03cf906cd19c61a1a1ebcf54 (patch)
tree2881990f6a09312441f35f1a5151d38177a57aba /.irssi
parent8c0f49ab9bef52fe82fbd37a8cb005a64aa525d3 (diff)
downloaddotfiles-fda0464cbab8590f03cf906cd19c61a1a1ebcf54.tar.gz
simplify/fix act.pl for my needs
Diffstat (limited to '.irssi')
-rwxr-xr-x[-rw-r--r--].irssi/scripts/autorun/act.pl34
1 files changed, 2 insertions, 32 deletions
diff --git a/.irssi/scripts/autorun/act.pl b/.irssi/scripts/autorun/act.pl
index f7a75281..252a6d38 100644..100755
--- a/.irssi/scripts/autorun/act.pl
+++ b/.irssi/scripts/autorun/act.pl
@@ -1,44 +1,14 @@
#!/usr/bin/perl -w
# resets window activity status
-# by c0ffee
-# - http://www.penguin-breeder.org/irssi/
+# based on act.pl from http://scripts.irssi.org by c0ffee
-#<scriptinfo>
use strict;
-use vars qw($VERSION %IRSSI);
-
use Irssi 20020120;
-$VERSION = "0.14";
-%IRSSI = (
- authors => "c0ffee",
- contact => "c0ffee\@penguin-breeder.org",
- name => "Reset window activity status",
- description => "Reset window activity status. defines command /act",
- license => "Public Domain",
- url => "http://www.penguin-breeder.org/irssi/",
- changed => "Thu Apr 16 15:55:05 BST 2015",
-);
-#</scriptinfo>
-
-#
-# /ACT [PUBLIC|ALL]
-#
-# /ACT without parameters marks windows as non-active where no
-# public talk occured.
-#
-# /ACT PUBLIC also removes those where no nick hilight was triggered
-#
-# /ACT ALL sets all windows as non-active
-Irssi::command_bind('act', sub { _act(1); });
-Irssi::command_bind('act public', sub { _act(2); });
-Irssi::command_bind('act all', sub { _act(3); });
+Irssi::command_bind('ac', sub { _act(); });
sub _act {
- my($level) = @_;
for (Irssi::windows()) {
- if ($_->{data_level} <= $level) {
Irssi::signal_emit("window dehilight", $_);
- }
}
}