1
0
Fork 0

.. lots of changes ..

git-svn-id: http://svn.irssi.org/repos/irssi/trunk@197 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2000-05-04 10:32:42 +00:00 committed by cras
parent bacfcb060c
commit d3dc9a1307
106 changed files with 4845 additions and 1578 deletions

17
NEWS
View File

@ -5,6 +5,11 @@ v0.7.90 2000-04-xx Timo Sirainen <tss@iki.fi>
compatible with EPIC as much as possible (except the scripting,
perl should be enough?)
* DOCUMENTATION! See docs/manual.txt
This NEWS file contains only the biggest new features, you should
browse through the documentation to find the rest.
* Irssi isn't anymore IRC specific client, you could easily take the
whole IRC part away and use some other chat protocol instead, or
use both at the same time. Currently however, only IRC protocol
@ -54,6 +59,8 @@ v0.7.90 2000-04-xx Timo Sirainen <tss@iki.fi>
This can be changed from settings `cmd_max_at_once' and
`cmd_queue_speed'. If you want to disable this for some reason, use
/SET cmd_queue_speed 0
+ Split windows in text version, all the normal ircII /WINDOW
commands should work: new, kill, grow, shrink, balance, show, hide
+ /EVAL <commands> - Expand all the special variables from string and
run it. Commands can be split with ; character. See
docs/special_vars.txt for more info.
@ -62,7 +69,7 @@ v0.7.90 2000-04-xx Timo Sirainen <tss@iki.fi>
$1..$9, now they're in $0..$8 so it messes up existing themes..
+ /SET [key [value]] - no more the '=' character. Boolean values
also need to be changed with ON/OFF/TOGGLE values (not yes/no).
+ /SAVE [<filename>] - saves the settings to disk.
+ /SAVE [<filename>] - saves the settings to file.
/REHASH [<filename>] - re-read the configuration file on the fly
+ /TOGGLE <key> [ON/OFF] - same as /SET <key> TOGGLE
+ /ALIAS [-]<alias> [<command>], /UNALIAS <alias>
@ -113,11 +120,11 @@ v0.7.90 2000-04-xx Timo Sirainen <tss@iki.fi>
The best match always wins, so you can have:
/IGNORE * CTCPS
/IGNORE -except *!*@host.org CTCPS
+ /LOG OPEN [-noopen] [-autoopen] [-channels <channels>] [-window]
+ /LOG OPEN [-noopen] [-autoopen] [-targets <targets>] [-window]
[-rotate hour|day|month] <filename> [<levels>]
-noopen: create the entry to log list, but don't start logging
-autoopen: automatically open this log file at startup
-channels: log only in specified channels/nicks
-targets: log only in specified channels/nicks
-window: Log this window
-rotate: Reopen the log file every hour, day or month. This
makes only sense if you specify date/time formats
@ -157,6 +164,10 @@ v0.7.90 2000-04-xx Timo Sirainen <tss@iki.fi>
your previous user mode and away message (and rejoin the channels,
which it already did before) after reconnected. If you use /SERVER
to connect to different IRC network, none of this will be done.
+ /CAT <filename> - prints the file to screen
+ /SET query_auto_close <secs> - automatically close queries after
<secs> seconds. It won't close queries that have unread messages,
and it won't close queries in the active window.
v0.7.28 2000-03-11 Timo Sirainen <tss@iki.fi>

43
README
View File

@ -13,8 +13,10 @@ also like to see KDE version.
* FEATURES
See docs/COMMANDS file for list of (almost) all commands irssi knows.
See docs/PERL for some documentation of Perl scripting.
docs/manual.txt - new manual
See docs/commands.txt file for list of (almost) all commands irssi knows.
See docs/perl.txt for some documentation of Perl scripting.
I've been asked quite a lot about why should one use irssi, what does it do
that other IRC clients don't? Well, to tell you the truth, I have no idea :)
@ -23,7 +25,6 @@ ever used :) Let's see.. It should be easy to use, it has most of the
features IRC client needs and it's pretty stable. Here's a small list of what
it does:
- Nice configuration :) Especially the color settings.
- You can connect to multiple servers. Irssi is also IRC network aware so
you can specify some settings to work only in specified IRC networks.
- Automatically connect to IRC server(s) at startup, automatically join to
@ -60,42 +61,6 @@ where your irc server is connected. Now just connect your clients to
the proxy. There's not much features yet, if you want to use multiple
servers you'll need to start multiple irssi-texts now..
* INSTALLATION
./configure
make
make install
Configure can use these parameters (all of these defaults to yes):
--with-servertest Build test irc server which you can use to try crash
irc clients
--with-socks Build with socks library
--with-mysql=dir Build with mysql plugin
--without-gtk Build without GTK frontend
--without-textui Build without text frontend
--without-bot Build without irssibot
--without-gnome Build without GNOME libraries
--without-gnome-panel Build without GNOME panel
--without-imlib Build without Imlib library (you can use only .xpm
files as backgrounds)
--enable-memdebug Enable memory debugging, great for finding memory
leaks
--enable-gtk-hebrew Enable Hebrew support - see README-HEBREW
--disable-perl Disable Perl support
There's also some others, you can get a full list with ./configure --help
* COMMAND LINE PARAMETERS
--no-applet Don't start gnome panel applet
--connect -c <server> Connect to server at startup
--port -p <port> - specify port
--noconnect -! Don't autoconnect to any servers at startup
--nick -n Specify what nick to use
--hostname -h Specify what host name to use
* BUGS / SUGGESTIONS
See TODO file if it is already listed in there - if not send me email..

43
TODO
View File

@ -1,7 +1,23 @@
- /IRCNET ADD/REMOVE
- mites se awaylogi? se /cattaamaan myös se /away:n jälkeen
- poista se common-setup.h
- quitissa se räpeltää ruutua liikaa..
- perli kaatui välillä ym. kivaa.
[21:48] < santo> [20:51] ¤¤¤ #twiggy,#tanum,#d2mac,#linux.nu,#sweden2k
Cannot join channel (illegal name)
.. /mode #a,#b voi sanoa myös jossain serverillä jotain outoa.. irc.carnet.hr
.. logit rehashissa sammuu, /window logit katoaa kokonaan? kai /window logit
pelaa oikein jos ikkunan refnum vaihtuu?
.. joosella oli joku bufferibugi. bufferi pieneksi, pguppia, paljon tekstiä
lisää, alas, --more-- jää
.. /sb bugaa! /SB GOTO 23:59 tms. ei pelaa
- rikki:
- dcc
- gnome versio..
- pluginit, perlskriptit
- pluginit
- teemat (toimiiko ne edes?)
- teeman vaihto tekstiversiolla, tekstien muuttaminen tekstiversiolla
@ -12,31 +28,23 @@
- use different themes in different channels/queries?
- logi voisi käyttää omaa teemaa
- mites se awaylogi?
- /WALL, ja sen replyt
- /ON
- /CAT
- servereiden ja ircnettien asetusten käpistelyyn jotkut käskyt
- curses sijainti jotain rikkoo
- /set hold_mode, ja /CAT toimimaan sen kanssa jotenkin nerokkaasti..
- curses sijainti jotain rikkoo, ja openbsd:ssä on -lcurses, ei -lncurses
- /msg =dcc_chatti,#kanava .. ei pelaa tollanen. voisi laittaa coreen tuon
ja jotain hookkeja et eri chattiprotoille voisi vaikka mennä se teksti..
ctcp:lle sama?
- who ja listiin ne eri vipuset
- /ON
- raiseta ikkuna jossa on tekstiä mut ei over aktiivisen päälle
- line-split.c: varmista että se 64k limitti toimii eikä esim. kaada!
- vaihda /set nimet järkevimmiksi
- /exec
- autorun.ircnet
- bottipluginiin tms. .. channel not available tms. rejoini
- channel not available rejoini
*** Bugs
- %| doesn't work with irssi text widget
- when changing server (/server), irssi will automatically join back to the
channels that were joined in previous server. If IRC network is different
than in previous server it shouldn't join the channels..
- some problems when using multiple windows with focus being all the time in
one of the windows and it can't be changed to different window?! Probably
has something to do with click to focus.
@ -48,12 +56,11 @@
*** text UI
- split windows
- statusbar:
- you can't configure it in any way!
- when starting to run out of space some items could be made smaller,
activity for example .. make some generic flag for items to use.
- "you have new mail"
- active server tag somewhere in window
*** Big things
@ -90,7 +97,7 @@
*** Needs rethinking ..
* Notify list, join the two different dialogs
* Notify list GUI
- _one_ popup dialog could open which lists all nicks in notifylist, maybe
sorted by arrival time, display the dates, latest joined could be with
different color? etc.
@ -122,7 +129,6 @@
mouse...
- if some other window has got much text, switching to it first time
takes some time..?
- exceptions for ignoring
- editor in setup for ~/.irssi/startup
- gui help
- change signal handling in gui-gnome so that the actual drawing and
@ -132,8 +138,6 @@
who are away and who are not.. optionally it could instead just watch if
someone hasn't written anything to channel in n minutes and mark it "away"
to nicklist.
- /connect ircnet could connect to ircnet
- change some GLists to GHashTables, aliases at least
- check new irssi versions with http rather than with irssibot..
- implement requesting files with DCC GET from remote client for dcc file
servers. good for people behind firewalls.
@ -145,6 +149,5 @@
- dcc send: allow selection of multiple files to send (also for dnd from
gmc!) Allow dropping files to anywhere in irssi.
- /timer, /clones
- display net splits?
- {}|~ are same as []\^ (not in all irc networks) - does this really affect
irssi at all..?

64
config
View File

@ -1,19 +1,19 @@
setupservers = (
{server = "irc.funet.fi"; ircnet = IRCNet; port = 6667; autoconnect = No;},
{server = "irc.efnet.net"; ircnet = EFNet; port = 6667; autoconnect = No;},
{server = "irc.undernet.net"; ircnet = Undernet; port = 6667; autoconnect = No;},
{server = "irc.dal.net"; ircnet = DALNet; port = 6667; autoconnect = No;},
{server = "irc.openprojects.net"; ircnet = OPN; port = 6667; autoconnect = No;},
{server = "irc.ptlink.net"; ircnet = PTlink; port = 6667; autoconnect = No;}
servers = (
{ address = "irc.funet.fi"; ircnet = IRCNet; port = 6667; },
{ address = "irc.efnet.net"; ircnet = EFNet; port = 6667; },
{ address = "irc.undernet.net"; ircnet = Undernet; port = 6667; },
{ address = "irc.dal.net"; ircnet = DALNet; port = 6667; },
{ address = "irc.openprojects.net"; ircnet = OPN; port = 6667; },
{ address = "irc.ptlink.net"; ircnet = PTlink; port = 6667; }
);
ircnets = (
{name = IRCNet; max_kicks = 4; max_modes = 3; max_msgs = 5; max_whois = 4;},
{name = EFNet; max_kicks = 4; max_modes = 4; max_msgs = 3;},
{name = Undernet; max_kicks = 4; max_modes = 3; max_msgs = 3;},
{name = DALNet; max_kicks = 4; max_modes = 6; max_msgs = 3;},
{name = OPN; max_kicks = 1; max_modes = 6; max_msgs = 100;},
{name = PTlink; max_kicks = 1; max_modes = 6; max_msgs = 100;}
{ name = IRCNet; max_kicks = 4; max_modes = 3; max_msgs = 5; max_whois = 4; },
{ name = EFNet; max_kicks = 4; max_modes = 4; max_msgs = 3; },
{ name = Undernet; max_kicks = 4; max_modes = 3; max_msgs = 3; },
{ name = DALNet; max_kicks = 4; max_modes = 6; max_msgs = 3; },
{ name = OPN; max_kicks = 1; max_modes = 6; max_msgs = 100; },
{ name = PTlink; max_kicks = 1; max_modes = 6; max_msgs = 100; }
);
channels = (
@ -28,6 +28,7 @@ channels = (
autojoin = No;
}
);
aliases = {
J = "join";
LEAVE = "part";
@ -62,23 +63,24 @@ aliases = {
WC = "window close";
WN = "window new";
};
popups = (
{label = "<MULTICOMMA>Whois"; command = "/whois %s";},
{label = "DCC Send File"; command = "/dcc send %s";},
{label = "Open DCC Chat"; command = "/dcc chat %s";},
{label = Query; command = "/query %s";},
{label = "<MENU><OP>"; command = "Op";},
{label = "<MULTI>Op"; command = "/op %s";},
{label = "<MULTI>Deop"; command = "/deop %s";},
{label = "<MULTI>Voice"; command = "/voice %s";},
{label = "<MULTI>Devoice"; command = "/devoice %s";},
{label = "<KICK>Kick"; command = "/kick %s %s";},
{label = "<MULTI>Ban"; command = "/ban %s";},
{label = "<KICK>Kick+ban"; command = "/kickban %s %s";},
{label = "<KICK>Knockout"; command = "/knockout %s %s";},
{label = "</MENU>"; command = "";},
{label = "<MENU>"; command = "CTCP";},
{label = Ping; command = "/ping %s";},
{label = Version; command = "/ver %s";},
{label = "</MENU>"; command = "";}
{ label = "<MULTICOMMA>Whois"; command = "/whois %s"; },
{ label = "DCC Send File"; command = "/dcc send %s"; },
{ label = "Open DCC Chat"; command = "/dcc chat %s"; },
{ label = Query; command = "/query %s"; },
{ label = "<MENU><OP>"; command = "Op"; },
{ label = "<MULTI>Op"; command = "/op %s"; },
{ label = "<MULTI>Deop"; command = "/deop %s"; },
{ label = "<MULTI>Voice"; command = "/voice %s"; },
{ label = "<MULTI>Devoice"; command = "/devoice %s"; },
{ label = "<KICK>Kick"; command = "/kick %s %s"; },
{ label = "<MULTI>Ban"; command = "/ban %s"; },
{ label = "<KICK>Kick+ban"; command = "/kickban %s %s"; },
{ label = "<KICK>Knockout"; command = "/knockout %s %s"; },
{ label = "</MENU>"; command = ""; },
{ label = "<MENU>"; command = "CTCP"; },
{ label = Ping; command = "/ping %s"; },
{ label = Version; command = "/ver %s"; },
{ label = "</MENU>"; command = ""; }
);

View File

@ -487,9 +487,9 @@ if test "x$want_perl" = "xyes"; then
old_dir=`pwd` && cd $srcdir && whole_dir=`pwd` && cd $old_dir
if test "x$old_dir" != "x$whole_dir"; then
ln -sf $whole_dir/plugins/perl/xs/typemap plugins/perl/xs/typemap
ln -sf $whole_dir/plugins/perl/xs/Irssi.xs plugins/perl/xs/Irssi.xs
ln -sf $whole_dir/plugins/perl/xs/Irssi.pm plugins/perl/xs/Irssi.pm
ln -sf $whole_dir/src/perl/xs/typemap src/perl/xs/typemap
ln -sf $whole_dir/src/perl/xs/Irssi.xs src/perl/xs/Irssi.xs
ln -sf $whole_dir/src/perl/xs/Irssi.pm src/perl/xs/Irssi.pm
fi
fi

983
docs/manual.txt Normal file
View File

@ -0,0 +1,983 @@
Irssi 0.8 documentation
Copyright(c) 2000 Timo Sirainen
Index
0. Generic babbling
1. Installation
2. Message levels
3. Flood protection
4. Configuration
5. Servers
6. Channels
7. IRC commands and features
8. Notify list
9. Text highlighting
10. Ignoring
11. Logging
12. Aliases
13. Themes
14. Last log (currently text version only)
15. Nick and word completion
16. Translation tables
17. Windowing system (text version)
18. Keyboard (text version)
19. Perl scripting
0. Generic babbling
0.1 History
Hello. I'm Timo Sirainen aka. cras, and I'm IRC addict. :)
I'm actually quite new in IRC, I got my first internet connection
sometimes around fall 1997 and I started actively IRCing around
christmas. I used EPIC and BitchX mostly at the start, but soon
found some nice KDE IRC client which name I can't remember anymore.
It's author however stopped developing it after I had been using it
a few months. And since it had bugs and all, I wanted another nice
GUI IRC client. I didn't find any.
Since I've always been a coder and do-it-yourself guy (my own
offline reader and BBS software in the BBS ages), I started my own
IRC client at spring 1998. I called it yagIRC standing for "Yet
another GTK IRC client". GTK was in around version 1.0 back then,
and it had a lot of features/bugs which I found all the time as I
tried to do some "different" things than other people. These
sometimes prevented me of doing something some feature I wanted.
So, in summer 1998 I went to army and I passed development of yagIRC
to two guys, they did a few new features and released a version or
two, but finally (in summer 1999?) they put a message to web page
which told that they finally had stopped developing it entirely,
also saying that my code was a total mess :) (yes, it was a mess)
I got out of the army 1.1.1999. I promised to myself that I wouldn't
do another IRC client, but after trying to use BitchX a while, I
started dreaming about an IRC client which would have an excellent
look and feel. After trying various things, I only came up with the
GNOME panel applet which people still tell me that it's a great
feature. I was more like thinking some pretty little icons in
some corner telling me about new messages and other stuff..
I thought that I would keep Irssi a small project, just doing a few
little features that *I* wanted, nothing for others. But after few
versions and few interested people, I started coding it more and
more generic..
Finally, after releasing version 0.6.0 (february, 1999) I realized
that things were getting into a big mess again. I started a rewrite,
I organized the code into irc-base, irc-extra, user interface and
GUI directories, created the signalling system for letting them
communicate themselves easily and released 0.7.0. This was the base
for the rest of the 0.7.x releases, and it did work pretty well.
The signalling system was excellent, for example creating text mode
version was really easy and you didn't need tens of (empty) gui_xxx()
functions like in the yagIRC days. Maintaining the text and GTK
versions separately was really easy too.
About a year later after releasing Irssi 0.7.0, I started having
dreams about an IRC client that would be extremely modular, like you
could upgrade the client to newer version ON THE FLY without needing
to even disconnect from the servers. I started a project codenamed
i2k, I took the code from Irssi, split it into more directories and
changed quite a lot of the code to work a bit differently.
I developed i2k quite a long, until I finally gave up with it since
it could do only some basic things, and Irssi 0.7 really needed
maintaining. After a while I got an idea, maybe I could merge the
code from the i2k to Irssi more easily than rewriting the whole
client. This was more easier than I thought. It's now been two
months since I started it, and Irssi 0.8 is looking absolutely
excellent.
0.2 Irssi 0.8
Irssi 0.8 is my fourth try to create the perfect IRC client.
This time I'm concentrating to the code. I try to avoid kludges, I
try to make as simple code as I can, and I try to provide enough
easy to use functions so that extending Irssi is as simple as
possible. I also try to keep the "bloat" features in scripts or
modules instead of build-in.
I think I'm succeeded with these goals pretty well, there's some
small problems but everything in the big picture looks great.
0.3 Future
What about Irssi 1.0, what will it look like?
I was thinking about the Linux kernel versioning and keeping
Irssi 0.8 a stable version all the time while developing new
features only to Irssi 0.9. After 0.9 is finished, it will be
called 0.10 or 1.0 depending if I think it's ready to be called 1.0.
1.0's goal is that it has all the possible features anyone will
ever need. If not build-in, then in scripts or loadable modules.
Not very small goal :)
0.4 This documentation
Strange, I just created the index list and started writing this.
I've never been too good at documentation and I usually don't like
writing it, but after coding so much recently and seeing that the
NEWS file was getting *SO* large, I thought that I had to put all
these features down somewhere so people (and me!) would find them.
Besides of just telling about Irssi's features and how to use them,
this file also contains some not so well known IRC features, some
of my own experiences, opinions, etc. So even if you're an
experienced IRCer, you might still want to browse through this file.
NOTE: my experiences are mostly IRCnet related, and Irssi is pretty
much IRCnet specific too, since it's the most commonly used IRC
network here in Finland. IRCnet has tens of servers here where as
other IRC networks have maybe one or two or mostly none.
1. Installation
1.1 Configuration
configure script accepts these parameters:
--with-servertest Build test irc server which you can use to
try crash irc clients
--with-socks Build with socks library
--with-mysql=dir Build with mysql plugin
--without-gtk Build without GTK frontend
--without-textui Build without text frontend
--without-bot Build without irssibot
--without-gnome Build without GNOME libraries
--without-gnome-panel Build without GNOME panel
--without-imlib Build without Imlib library (you can use only
.xpm files as backgrounds)
--enable-memdebug Enable memory debugging, great for finding
memory leaks
--enable-gtk-hebrew Enable Hebrew support - see README-HEBREW
--disable-perl Disable Perl support
In short:
./configure
make
make install
1.2 Command line parameters
--connect -c <server> Connect to server at startup
--port -p <port> - specify port
--noconnect -! Don't autoconnect to any servers at startup
--nick -n Specify what nick to use
--hostname -h Specify what host name to use
--no-applet Don't start GNOME panel applet
2. Message levels
Message levels (or in short, levels) are used almost everywhere.
They describe what kind of messages we're dealing with. Here's a
list of them all:
CRAP - Can be almost anything
MSGS - Private messages
PUBLIC - Public messages in channel
NOTICES - Notices
SNOTES - Server notices
CTCPS - CTCP messages
ACTIONS - Actions (/me) - both private and public
(which is a bit problematic..)
JOINS - Someone joins a channel
PARTS - Someone parts a channel
QUITS - Someone quits IRC
KICKS - Someone gets kicked from channel
MODES - Channel mode is changed
TOPICS - Channel topic is changed
WALLOPS - Wallop is received
INVITES - Invite is received
NICKS - Someone changes nick
DCC - DCC messages
CLIENTNOTICES - Irssi's notices
CLIENTERRORS - Irssi's error messages
CLIENTCRAP - Some other messages from Irssi
HILIGHT - Hilighted text
NOHILIGHT - Don't use hilighting for this message
3. Flood protection
3.1 Command flood protection
Most (all?) IRC servers' flood protection works like this
(from RFC 1459):
--------
* check to see if client's `message timer' is less than
current time (set to be equal if it is);
* read any data present from the client;
* while the timer is less than ten seconds ahead of the current
time, parse any present messages and penalize the client by
2 seconds for each message;
which in essence means that the client may send 1 message every 2
seconds without being adversely affected.
--------
Irssi's flood protection works the same way, except it penalizes
2.2 seconds by default for each message (helps with some servers).
You can change it with /SET cmd_queue_speed <milliseconds>. You can
also change the number of commands before flood protection activates
(ie. the burst count) with /SET cmd_max_at_once <count>.
IRC servers also have an input buffer where the client's commands
are saved before processed. It's size is server specific (can be as
low as 1k!) If it gets full, the server kicks you out (the
"Excess flood" quit message). Irssi's flood protecion protects this
pretty well with small commands, but if you send many big commands
(like >400 char long messages) fast, you could get easily kicked out.
Normally this isn't problem, but if you have scripts sending long
messages, you should remember this. I'm not sure how much you should
wait between the long messages, but 2 seconds isn't enough.
This protection is used with all commands sent to server, so you
don't need to worry about it with your scripts.
3.2 CTCP flood protection
Other people can pretty easily flood you with CTCP requests, and
even if you wouldn't get kicked out from the server, they could
easily grow your command queue. So, Irssi's CTCP flood protection
works like this:
First it checks how big the CTCP reply queue is, if it's longer
than `max_ctcp_queue', the CTCP is ignored. You can change it with
/SET max_ctcp_queue <count> (default is 5).
After this the CTCP reply is placed to server's "idle queue", so
the reply is sent "when there's extra time", this means that if
you are busy sending other commands, it might take a while before
the reply is sent.
3.3 Detecting floods
Irssi is all the time automatically checking different flooding,
when flood is noticed, it sends "flood" signal. This can be easily
used for example to create a script for kicking channel flooders.
Autoignore uses this also, see section 10.2.
Flood is detected when more than `flood_max_msgs' same kind of
messages arrives in `flood_timecheck' milliseconds to same target
(channel or private msg) so it isn't flooding if same user sends a
message to 10 different channels you are on, but it is flooding if
10 messages are sent to same channel by the same user.
Currently only messages, notices and ctcps are checked for
flooding.
/SET flood_max_msgs = <count>, default is 4
/SET flood_timecheck = <milliseconds>, default is 5 seconds
If either of these is 0, the flood checking is disabled.
4. Configuration
4.1 Configuration files
The configuration is saved to ~/.irssi/config file. You can edit
it with text editor if you want, you can also add comments to it
and they stay there even if /SAVE is used. Comments are the lines
starting with # character. Any errors in config file are displayed
at startup.
Irssi uses it's own config library for handling the config file.
The format is pretty much the same as in libPropList and should be
easily understandable.
You can reload the config file on the fly with /REHASH command, you
can also read a different config file with /REHASH <filename>.
If you change any settings, they aren't saved to file until you use
/SAVE. You can save the config file to different place with
/SAVE <filename>.
4.2 Settings
You can view or change the settings with /SET command.
/SET without any arguments displays all the settings.
/SET <key> displays settings which key (partly) matches <key>
/SET <key> <value> sets <key> to <value>
Boolean settings accepts only values ON, OFF and TOGGLE. You can
also use /TOGGLE command to change them, so /TOGGLE <key> behaves
like /SET <key> TOGGLE. /TOGGLE also accepts arguments ON and OFF
when /TOGGLE behaves exactly like /SET.
Remember that changes are not saved until you use /SAVE!
5. Servers
5.1 Generic
Irssi is multi-server friendly. You can be connected to multiple
different servers, or the same server multiple times. Most of the
settings that let you specify the channel, let you also specify IRC
network.
Servers are referenced by a "server tag". If the server is known
to belong to some IRC network, the tag is the IRC network's name,
like "ircnet". If the IRC network is unknown, the tag is created
from the server's name, like irc.funet.fi -> funet. If the tag
already exists, a number is added to the end of it and raised until
unused tag is found.
Quit messages have a small problem if there's already a few
commands in server's input command queue. If the server's socket is
disconnected immediately after QUIT message is sent, it is possible
that the server didn't yet process the quit command and your quit
message will be "broken pipe" or something similiar. The right thing
to do is to let the server disconnect you, but what if the
connection to server is broken and the server never disconnects you?
I solved the problem by waiting a few seconds to see if the server
disconnects us. If it didn't, force the disconnect. This explains
the (a bit annoying) "waiting for servers to close connections"
message when quiting Irssi. Most IRC clients just ignore this whole
problem, but I hate it if my quit message isn't displayed right.
5.2 IRC networks
Different IRC networks behave a bit differently, and to be as
efficient as possible, Irssi needs to know a few things about them
or the safe defaults will be used. The default configuration file
contains the settings for the biggest IRC networks.
/IRCNET ADD [-kicks <count>] [-msgs <count>] [-modes <count>]
[-whois <count>] [-cmdspeed <ms>] [-cmdmax <count>]
[-nick <nick>] [-user <user>] [-name <name>]
[-host <host>] <name>
-kicks: Maximum number of nicks in one /KICK command
-msgs: Maximum number of nicks in one /MSG command
-modes: Maximum number of mode changes in one /MODE command
-whois: Maximum number of nicks in one /WHOIS command
-cmdspeed: Same as /SET cmd_queue_speed, see section 3.1
-cmdmax: Same as /SET cmd_max_at_once, see section 3.1
-nick, -user, -name: Specify what nick/username/realname to use
-host: Specify what host name to use, if you have multiple
/IRCNET REMOVE <name>
5.3 Manually connecting and disconnecting
To connect to a new server, use:
/CONNECT [-ircnet <ircnet>] [-host <hostname>] <address>|<ircnet>
[<port> [<password> [<nick>]]]
If there's no password, set it to -. You can directly connect to
IRC server in specified address, or you can connect to some IRC
network and Irssi will pick the server for you.
You don't need to specify the IRC network, password, nick, etc. if
you setup the server using /SERVER -add (see next section). If the
settings can't be found there either, Irssi will use the defaults:
/SET default_nick = <nick>, defaults to user_name
/SET alternate_nick = <nick>, defaults to <default_nick>_
/SET user_name = <user>, defaults to your login name
/SET real_name = <name>, taken from /etc/passwd by default
/SET hostname = <host>, what host name to use when connecting
/SET skip_motd ON|OFF|TOGGLE - Don't show server's MOTD
NOTE: /CONNECT is also a command for IRC operators to connect IRC
servers to other IRC servers. If you want to use it, use /SCONNECT
instead.
You can disconnect from the server with:
/DISCONNECT *|<tag> [message]
If message isn't given, Irssi will use the default quit message. You
can set it with /SET quit_message <message>, default is "leaving".
/SERVER disconnects the server in active window and connects to new
one. It will take the same arguments as /CONNECT. If you prefix the
address with + character, Irssi won't disconnect the active server,
and it will create a new window where the server is connected
(ie. /window new hide;/connect address)
/SERVER without any arguments displays list of connected servers.
5.4 Server settings
/SERVER -add [-auto] [-ircnet <ircnet>] [-host <hostname>]
[-cmdspeed <ms>] [-cmdmax <count>] <address>
[<port> [<password> [<nick>]]]
-auto: Automatically connect to server at startup
-ircnet: Specify what IRC network this server belongs to
-host: Specify what host name to use, if you have multiple
-cmdspeed: Same as /SET cmd_queue_speed, see section 3.1
-cmdmax: Same as /SET cmd_max_at_once, see section 3.1
/SERVER -remove <address> [<port>]
/SERVER -list
After connected to server, Irssi can automatically change your user
mode. You can set it with /SET usermode <mode>, default is +i.
5.5 Automatic reconnecting
If you get disconnected from server, Irssi will try to reconnect
back to some of the servers in the same IRC network. To prevent
flooding the server that doesn't let you in (and avoiding K-lines),
Irssi won't try to reconnect to the same server more often than
once in `server_reconnect_time' seconds. You can change it with
/SET server_reconnect_time <seconds>, default is 5 minutes.
After reconnected to server, Irssi will re-set your user mode, away
message and will join you back to the same channels where you were
before the connection was lost.
You can see list of the reconnections with /SERVER. The servers
that have tag as RECON-n are the reconnections. You can remove them
with /DISCONNECT <tag>, and you can reconnect to them immediately
with /RECONNECT <n>. /RECONNECT without any arguments will
disconnect from the active server and reconnect back immediately.
5.6 Command redirections
FIXME
5.7 Server idle command queue
There's some situations when you want to ask something from the
server which isn't really important. For example when connected
to server and you didn't get your nick, Irssi asks with /WHOIS
who has your nick and displays it. But if you already have a lot of
commands in buffer, like you just autojoined to many channels,
you'd rather first let the JOIN commands to be sent to server
This is where server idle queue gets into picture. Commands in
idle queue are sent to server when there's nothing else in the
normal command queue.
Idle queue works with server redirections, so you can ask something
from server when it has time and your function is called when the
reply is received.
5.8 Net splits
Irssi keeps track of people who were lost in net splits. You can
get a list of them with /NETSPLIT command.
Another use for this is with bots. Channel master can op anyone in
the channel and the bot happily accepts it. But if the opped user
is lost behind a net split and in netjoin the server gives ops for
the user, the bot should decide if the user (who isn't in bot's user
database) is a malicious attacker who should be deopped, or if
he/she/it is just some user that already had ops before the net
split.
/SET hide_netsplit_quits - If ON, when detected net splits, display
only "Net split host1 host" message and hide all the quit
messages
5.9 Lag checking
Irssi will constantly check how big the lag to the server is. It's
done by sending IRSSILAG CTCP replies to ourself. Using PING command
for this would seem more reasonable, but there was too many problems
with it - some servers didn't even know the whole PING command!
If the lag is too big, Irssi will reconnect to different IRC server.
This is sometimes useful if the connection has been stuck for 30
minutes but it still hasn't been closed.
/SET lag_check_time <seconds> - Specifies how often to check the
lag. If it is set to 0, the lag detection is disabled. Default
is 30 seconds.
/SET lag_max_before_disconnect <seconds> - Specifies how big the lag
can be before reconnecting to another server. Default is 5
minutes.
/SET lag_min_show <100th seconds> - Specifies the minimum lag to
display in status bar. Default is 1 second.
5.10 Raw log
All data that is received or sent to server is kept in a raw log
buffer for a while. Also event redirections are kept there. This is
very useful for debugging purposes.
/RAWLOG SAVE <filename> - Save the current raw log buffer to file
/RAWLOG OPEN <filename> - Like /RAWLOG SAVE, but keep the log file
open and write all new log to it.
/RAWLOG CLOSE - Close the open raw log
/SET rawlog_lines <count> - Specify the number of raw log lines to
keep in memory.
6. Channels
6.1 Generic
There's several types of channels you can join, here's a list of
the ones that Irssi supports:
#channel - Normal channels, most commonly used
+channel - Modeless channels, channel has no modes, no channel
operators and no topic. This way no-one is above others
and there's no operator-wars etc. But on the other hand,
you can't kick any troublemakers..
&channel - Local channels, these channels aren't distributed outside
the IRC server. IRCNet has replaced server notices with
several different &channels (&ERRORS, &NOTICES, etc.)
!channel - New channels, currently supported only by IRCNet. These
channels are designed so that they can't be taken over
with net splits. /JOIN !channel joins to existing
!channel, /JOIN !!channel creates a new channel.
6.2 Joining, parting
Channels can be joined with /JOIN command. You can join to multiple
channels with one /JOIN by giving it a comma-separated list of
channels, like /JOIN #channel1,#channel2. If you don't give the
channel mode character (#+&!) before the channel name, Irssi
automatically uses # channels.
Channel name may contain any characters except SPACE, BELL, NUL,
CR, LF or comma (','). You can also restrict the channel to only
certain users by adding the hostmask to the end of the channel
name separated with a ':' character, like #channel:*!*@*.fi lets
only people from .fi domain join the channel. This doesn't work with
all IRC servers and it's pretty difficult to use, since everyone
will have to always join the #channel:*!*@*.fi channel, #channel or
#channel:*!*@*.se channels are different channels. Ban exceptions
(+e) and especially invite lists (+I) replace this functionality
pretty well, see section 6.5.
If channel has a password (aka. key), you can join it with
/JOIN #channel pass, or multiple channels with passwords with
/JOIN #secret1,#public,#secret2 pass1,x,pass2
#public didn't have any password, so we used "x" as it's password.
It doesn't really matter what password you send with channels that
don't have passwords.
You can leave channels with /PART [<channels>] [<part message>].
For example "/PART byebye all" leaves the active channel with
"byebye all" message, or /PART #chan1,#chan2 leaves those channels.
NOTE: Sending JOIN 0 directly to server (/quote join 0) leaves all
the channels you are joined. There's been some jokes about joining
for example to #2000,0 where the server actually leaves you from all
channels. With Irssi this isn't really a problem, since irssi would
happily join to channels #2000 and #0.
6.3 Automatic joining
Irssi can automatically join to specified channels in specified
IRC networks. It can also automatically send the password when
manually joining to channel without specifying the password.
/CHANNEL ADD [-auto] [-bots <botmasks>] [-botcmd <command>]
<channel> <ircnet> [<password>]
With -bots and -botcmd arguments you can automatically send
commands to someone in channel. This is useful for automatically
getting ops for channels, for example
/CHANNEL ADD -auto -bots "*!bot@bothost.org bot*!*@host2.org"
-botcmd "msg $0 op mypass" #channel ircnet
You can also use the -botcmd without -bots argument. The command is
then sent whenever you join the channel.
You can remove the channels with
/CHANNEL REMOVE <channel> <ircnet>
/CHANNEL LIST displays list of channels with settings.
/CHANNEL without any arguments displays list of channels you have
joined. You can also use /CHANNEL to join to channels just as with
/JOIN, like /CHANNEL #a.
6.4 After-join automation
When joined to channel, Irssi asks some information about it.
After it has got all of it, it prints the "Channel synchronized"
text. The following information is asked:
- Channel mode
- WHO list to get nicks' hosts - useful for /BAN for example
- Ban list - useful for allowing /UNBAN to use wildcards
- Exception list, Invite list - these are asked only from servers
that support +I and +e modes, mostly just IRCNet and some EFNet
servers. These aren't really needed for anything currenty, except
/INVITELIST and /BANS uses them to display the lists.
If you have joined many channels at once, Irssi tries to optimize
the commands it sends to server. Instead of sending two commands
to ask two channels' mode, it just sends MODE #a,#b. Same thing with
WHO list and ban/except/invite lists. Some servers do not support
this and they reply with different kinds of error messages, Irssi
tries to deal with them all right and resend the commands again
separately. However, some strange servers sometimes use some weird
error replies that Irssi doesn't know about, and the channel never
gets synchronized. If this happens with some server you know, please
let the Irssi's author know about it.
6.5 Channel modes
Irssi knows these channel modes:
i - Invite only - People can't join to channel without being
/INVITEd, or being in invite list (+I, see below).
m - Moderated - People who don't have voices (+v) can't send
messages to channel
p - Private - People who aren't joined to channel can't see it
for example with /WHOISing people who are in channel.
s - Secret - Like private, but the channel isn't displayed in
/LIST's output.
n - No external msgs - Without this mode, anyone can send messages
to channel without even being joined.
t - Topic can be changed only by channel operators.
k <key> - Channel password (aka. key) - The channel can't be joined
without specifying the channel key (see section 6.2).
l <count> - User limit - No more than <count> people can join to
channel. This can be overridden with /INVITE with some
servers.
This is usually used for protecting channel from join
flooding, like some bot allows max. 5 users to join in
one minute or so.
a - Anonymous - No-one's nick name, host or anything else can be
seen. All messages, joins, parts, modes, etc. are seen as coming
from nick "anonymous", this could be pretty confusing but nice
feature if you want total anonymity. This mode can only be set,
never unset. This mode isn't supported by all servers.
NOTE: there is/was one bug :) Channel operators can guess if some
nick might be in the channel and try to kick it. If nick was in
channel, everyone will see the nick that was kicked.
r - Re-op - If channel becomes opless for longer than 45 (?) minutes,
op everyone in the channel. This works only in !channels. This
mode can only be set, not unset by channel creator.
b - Set/remove ban. For example MODE #channel +b *!*@*.org bans
everyone from .org domain.
If someone from .org domain was already in channel before the
ban was set, he/she couldn't be able to write any messages to
channel (doesn't work with all servers).
Ban can also be overridden with /INVITE, although many stupid
IRC clients automatically kick the user out because they see
the ban and think that because of it the user shouldn't be in
the channel (doesn't work with all servers).
e - Ban exceptions. You could for example ban everyone from
*!*@*.org but set ban exception to *!*@*.host.org - works only
in IRCnet/EFnet servers.
I - Invite list. If channel is invite only (+i), people in this
list can join it without being /INVITEd - works only in
IRCnet/EFnet servers.
This is excellent for in-country channels that don't want
foreigners (spammers!) to join the channel, for example setting
channel's mode to +i and +I *!*@*.fi allows only finnish people
to join the channel. In addition to this, there's usually a bot
in the channels and sending /MSG bot invite command to it
/INVITEs you to the channel.
The ':' feature in channel modes is quite similiar, see section
6.2.
O - Channel owner, the nick who creates a !channel receives this
mode. It isn't displayed anywhere, you can't pass it to anyone
else and you can't regain it again. This is needed for setting
+r mode in channel when it's first created.
o <nick> - Grant or revoke channel operator status from nick
v <nick> - Grant or revoke voice status from nick, only people with
+v (or +o) can talk to channel when it's moderated (+m).
You can send multiple mode changes with one mode command:
/MODE #channel +nto-o+v nick1,nick2,nick3
This would set channel's mode to +nt, give ops to nick1, take ops
from nick2 and give voices to nick3.
You can set only limited number of modes that requires argument in
one command. In IRCnet it's 3, in EFnet it's 4 and in many others
it's 6. If it's not known, Irssi defaults to 3. Irssi will also
automatically split them, so you can use /MODE +oooooo n1,n2,..
command to op 6 people and Irssi will split it to two commands in
IRCnet/EFnet.
Instead of manually setting o, v and b modes you probably want to
use /OP, /DEOP, /VOICE, /DEVOICE, /BAN and /UNBAN commands.
/OP, /DEOP, /VOICE and /DEVOICE commands allows wildcards as their
argument. So /OP ni* will op all non-opped people whose nick start
with "ni". /DEOP * will deop everyone else except you. /VOICE and
/DEVOICE work the same way.
6.6 Bans
You can give /BAN a list of nicks or whole ban masks. /UNBAN
accepts wildcards, so if you have ban nick!user@reallylonghost.org,
you can simply unban it with /UNBAN *really*
Using /BAN <nicks>, Irssi will automatically create the mask. You
can change the way it's created with /BANTYPE command:
/BANTYPE normal|host|domain|custom
Normal - *!user@*.domain.net
Host - *!*@host.domain.net
Domain - *!*@*.domain.net
Custom [nick] [user] [host] [domain]
eg. /bantype custom nick domain - nick!*@*.domain.net
eg. /bantype custom user host - *!user@host.domain.net
Irssi has also a couple of commands to help banning people:
/KICKBAN [<channel>] <nick> <reason> - ban and kick the nick
/KNOCKOUT [<seconds>] <nick> <reason> - kickban the nick, unban
after waiting <seconds>, default is 5 minutes.
6.7 Massjoins
Automatic opping the nick right after joined to channel is a pretty
commonly used. What mostly irritates me with this is that the nick
may be opped multiple times by different people, or after netsplits
when the people join back, the server will op them, but still the
bots op the people again, even if it was just done by the server.
Irssi has this feature that it sends a "massjoin" signal a while
after the real join. If someone has already opped the nick, you can
easily check it in the massjoin signal handler.
The default is to report maximum of 5 joins in one massjoin signal.
If the 5 joins don't come in 5 seconds, the signal is sent anyway.
You can change these with /SET massjoin_max_wait <milliseconds> and
/SET massjoin_max_joins <count>.
7. IRC commands and features (FIXME)
7.x Basic commands
7.x IRC operator commands
7.x Away features
8. Notify list
Notify list is generally used for knowing when someone you know
comes to IRC or leaves from IRC. Traditionally notify list can
handle only a list of nicks, no nick masks etc. I lost interest to
traditional notify lists long time ago, since the people I know
are in IRC all the time. So I made a bit more featureful notify
list:
/NOTIFY [-list] [-away] [-idle [minutes]] <mask> [ircnet [ircnet...]]
-away: Notifies about away-status changes
-idle: Notifies if idle time is first larger than <minutes>
(default is hour) and then it drops down.
-list: Lists the notify list entries with all their settings
<mask>: Either a simple "nick" or "nick!*@*blah.org". The nick
can't contain wildcards, but the user/host can.
/UNNOTIFY <mask>
/NOTIFY without any arguments displays if the people in notify
list are online or offline.
9. Text highlighting
Irssi supports highlighting lines that match the specified pattern.
You can also change the color of the nicks that match specified nick
mask, so you could for example show your friends' nicks with
different color.
/HILIGHT [-nick | -regexp | -word] [-color <color>]
[-level <level>] [-channels <channels>] <text>
-nick: Match only for nick, <text> is a nick mask
-regexp: <text> is a regular expression
-word: <text> must match to full words
-color: Print the reply with <color> - see below
-level: Match only for <level> messages, default is
publics,msgs,notices,actions
-channels: Match only in <channels>
/DEHILIGHT <ref#> | <text>
/HILIGHT without any arguments displays list of the hilights.
By default the highlighted line will be printed with white color.
You can change this with the -color argument. If <color> is a
number, Irssi will treat it as a MIRC color code. You can also use
bolds (^B), underlines (^_) etc. as <color> if you like.
10. Ignoring
10.1 Manual ignoring
Irssi's ignoring options should be enough for everyone :)
/IGNORE [-regexp | -word] [-pattern <pattern>] [-except]
[-channels <channel>] <mask> <levels> <^levels>
-regexp: <pattern> is a regular expression
-word: <pattern> must match to full words
-pattern: <pattern> must match to the message's text
-except: *DON'T* ignore
-channels: Ignore only in channels
<mask>: Either a nick mask or list of channels
<levels>: List of levels to ignore
<^levels>: List of levels to NOT ignore
(/ignore -except nick notices = /ignore nick ^notices)
/UNIGNORE <ref#> | <mask>
/IGNORE without any arguments displays list of ignores.
The best match always wins, so you can have:
/IGNORE * CTCPS
/IGNORE -except *!*@host.org CTCPS
10.2 Automatic ignoring
Irssi can automatically set ignores for people who flood you.
Currently you can autoignore MSGS, NOTICES, CTCPS and PUBLIC.
Actions are placed to either MSGS or PUBLIC. See section 3.3 for
definition of the flood.
/SET autoignore_time <seconds> specifies how long to ignore the
user.
/SET autoignore_levels <levels> specifies what levels to ignore
automatically, default is to ignore only CTCPS.
11. Logging
11.1 Basic logging
/LOG OPEN [-noopen] [-autoopen] [-targets <targets>] [-window]
[-rotate hour|day|week|month] <filename> [<levels>]
-noopen: Create the entry to log list, but don't start logging
-autoopen: Automatically open this log file at startup
-targets: Log only in specified channels/nicks
-window: Log the active window
-rotate: Reopen the log file every hour, day, week or month.
This makes only sense if you specify date/time formats
to file name.
<filename>: File name where to log, it is parsed with
strftime(), so %d=day, etc. see "man strftime" for
more info.
<levels>: Defaults to ALL
/LOG CLOSE <ref#> | <fname> - Close log and remove from log list
/LOG START <ref#> | <fname> - Start logging to file
/LOG STOP <ref#> | <fname> - Stop logging to file
/LOG without any arguments displays the log list
/SET log_create_mode <mode> - Specifies what file mode to use with
the created log files. Default is 0644.
All of these are parsed with strftime():
/SET log_timestamp <text> - Specifies the time stamp format.
Default is "%H:%M ".
/SET log_open_string <text> - Text written to log when it's opened
/SET log_close_string <text> - Text written to log when it's closed
/SET log_day_changed <text> - Text written to log when day changes
NOTE: Log files are locked after opened, so two Irssis can't
accidentally try to write to the same log file.
Examples:
/LOG OPEN -targets cras ~/irclogs/cras.log MSGS
- Logs all messages from/to nick `cras'
/LOG OPEN -rotate day -targets #linux ~/irclogs/linux/linux-%Y-%m-%d
- Logs all messages in channel #linux. Log is rotated daily, so
logs in 1. May 2000 goes to file "linux-2000-05-01", when the
day is changed, Irssi closes the log and starts logging to
"linux-2000-05-02" etc.
11.2 Window logging
/WINDOW LOG ON|OFF|TOGGLE [<filename>]
Start/stop logging the active window. This works exactly like
/LOG OPEN -window.
/WINDOW LOGFILE <filename>
Sets the default log file to use in the window, it can be
overridden with specifying the file name in /WINDOW LOG. If no file
name isn't given, Irssi defaults to ~/irc.log.<windowname> or
~/irc.log.Window<ref#> if window doesn't have name.
Creates the entry to log list, same as /LOG OPEN -window -noopen.
Also, if /WINDOW LOG ON is used it starts logging to this file.
11.3 Automatic logging
This is the logging method that I had been asked to implement for
ages, and it is really simple to use too. It logs only messages
that have "targets", ie. private messages and channel specific
messages (msgs, modes, topics, etc). WHOIS replies and such aren't
logged. If you with to log them too, use the /LOG command.
So, when for example a private messages comes to you from "guy"
nick, Irssi creates a log file ~/irclogs/guy.log for it. After few
minutes of inactivity, the log file is closed.
/SET AUTOLOG ON|OFF|TOGGLE - Enable/disable autolog.
/SET AUTOLOG_LEVEL <level> - Specifies what levels to log, default
is ALL.
/SET AUTOLOG_PATH <path> - expandos (see special_vars.txt) can be
used, $0 is the target. If you are using multiple servers, it makes
sense to use the server tag as part of the file name, for example
~/irclogs/$tag/$0.log (this is the default). The directories are
created automatically.
11.4 Awaylog
Irssi logs specified messages when you're away. After you set
yourself unaway, Irssi will display all the messages in the awaylog.
/SET awaylog_level <level> - Default is MSGS HILIGHT
/SET awaylog_file <filename> - Default is ~/.irssi/away.log
You can disable this feature by setting awaylog_level to NONE.

View File

@ -95,6 +95,7 @@ server.c:
"server connecting", SERVER_REC, ulong *ip
"server looking", SERVER_REC
"server disconnected", SERVER_REC
"server quit", SERVER_REC, char *msg
"event connected", SERVER_REC
server-reconnect.c:
@ -148,7 +149,7 @@ dcc.c:
flood.c:
"flood", SERVER_REC, char *nick, char *host, char *level, char *target
"flood", SERVER_REC, char *nick, char *host, int level, char *target
ignore.c:

View File

@ -1,5 +1,4 @@
NOTE: This is just a slightly modified file taken from EPIC's help.
'!' at start of the line means that the feature doesn't work yet..
Special Variables and Expandos
@ -70,7 +69,7 @@ $A .. $Z is important.
$R version of current server
$S current server name
$T target of current input (channel or QUERY nickname)
! $U value of cutbuffer
! $U value of cutbuffer (*DOES NOT WORK* - there is no cut buffer..)
$V client release date (numeric version string)
$W current working directory
$X your /userhost $N address (user@host)

View File

@ -64,12 +64,12 @@ src/fe-common/core/fe-settings.c
src/fe-common/core/hilight-text.c
src/fe-common/core/keyboard.c
src/fe-common/core/module-formats.c
src/fe-common/core/nick-hilight.c
src/fe-common/core/printtext.c
src/fe-common/core/themes.c
src/fe-common/core/translation.c
src/fe-common/core/window-items.c
src/fe-common/core/windows.c
src/fe-common/core/window-activity.c
src/fe-common/irc/dcc/fe-dcc.c
src/fe-common/irc/dcc/module-formats.c
src/fe-common/irc/completion.c
@ -82,20 +82,22 @@ src/fe-common/irc/fe-ignore.c
src/fe-common/irc/fe-irc-commands.c
src/fe-common/irc/fe-query.c
src/fe-common/irc/irc-hilight-text.c
src/fe-common/irc/irc-nick-hilight.c
src/fe-common/irc/module-formats.c
src/fe-common/irc/flood/fe-flood.c
src/fe-common/irc/flood/module-formats.c
src/fe-common/irc/notifylist/fe-notifylist.c
src/fe-common/irc/notifylist/module-formats.c
src/fe-common/irc/fe-irc-server.c
src/fe-common/irc/irc-window-activity.c
src/fe-common/irc/fe-netsplit.c
src/fe-none/irssi.c
src/fe-text/gui-entry.c
src/fe-text/gui-mainwindows.c
src/fe-text/statusbar.c
src/fe-text/mainwindows.c
src/fe-text/gui-printtext.c
src/fe-text/gui-readline.c
src/fe-text/gui-special-vars.c
src/fe-text/gui-statusbar-items.c
src/fe-text/gui-statusbar.c
src/fe-text/statusbar-items.c
src/fe-text/gui-textwidget.c
src/fe-text/irssi.c
src/fe-text/module-formats.c

View File

@ -16,9 +16,6 @@
/* How often to check for gone status of nick */
#define MAX_GONE_REFRESH_TIME 300
/* Maximum time to wait for more JOINs before sending massjoin signal */
#define MAX_MASSJOIN_WAIT 5000
/* How long to keep netsplits in memory (seconds) */
#define NETSPLIT_MAX_REMEMBER (60*30)

View File

@ -36,7 +36,6 @@ static char *levels[] =
"KICKS",
"MODES",
"TOPICS",
"WALLS",
"WALLOPS",
"INVITES",
"NICKS",

View File

@ -20,17 +20,16 @@
#define MSGLEVEL_KICKS 0x0000400
#define MSGLEVEL_MODES 0x0000800
#define MSGLEVEL_TOPICS 0x0001000
#define MSGLEVEL_WALLS 0x0002000
#define MSGLEVEL_WALLOPS 0x0004000
#define MSGLEVEL_INVITES 0x0008000
#define MSGLEVEL_NICKS 0x0010000
#define MSGLEVEL_DCC 0x0020000
#define MSGLEVEL_CLIENTNOTICE 0x0040000
#define MSGLEVEL_CLIENTCRAP 0x0080000
#define MSGLEVEL_CLIENTERROR 0x0100000
#define MSGLEVEL_HILIGHT 0x0200000
#define MSGLEVEL_WALLOPS 0x0002000
#define MSGLEVEL_INVITES 0x0004000
#define MSGLEVEL_NICKS 0x0008000
#define MSGLEVEL_DCC 0x0010000
#define MSGLEVEL_CLIENTNOTICE 0x0020000
#define MSGLEVEL_CLIENTCRAP 0x0040000
#define MSGLEVEL_CLIENTERROR 0x0080000
#define MSGLEVEL_HILIGHT 0x0100000
#define MSGLEVEL_ALL 0x03fffff
#define MSGLEVEL_ALL 0x01fffff
#define MSGLEVEL_NOHILIGHT 0x1000000 /* Don't try to hilight words in this message */
#define MSGLEVEL_NO_ACT 0x2000000 /* Don't trigger channel activity */

View File

@ -60,7 +60,9 @@ static char *server_create_address_tag(const char *address)
const char *start, *end;
/* try to generate a reasonable server tag */
if (g_strncasecmp(address, "irc", 3) == 0 ||
if (strchr(address, '.') == NULL) {
start = end = NULL;
} else if (g_strncasecmp(address, "irc", 3) == 0 ||
g_strncasecmp(address, "chat", 4) == 0) {
/* irc-2.cs.hut.fi -> hut, chat.bt.net -> bt */
end = strrchr(address, '.');
@ -224,14 +226,14 @@ SERVER_REC *server_find_tag(const char *tag)
for (tmp = servers; tmp != NULL; tmp = tmp->next) {
SERVER_REC *server = tmp->data;
if (strcmp(server->tag, tag) == 0)
if (g_strcasecmp(server->tag, tag) == 0)
return server;
}
for (tmp = lookup_servers; tmp != NULL; tmp = tmp->next) {
SERVER_REC *server = tmp->data;
if (strcmp(server->tag, tag) == 0)
if (g_strcasecmp(server->tag, tag) == 0)
return server;
}
@ -249,7 +251,7 @@ SERVER_REC *server_find_ircnet(const char *ircnet)
SERVER_REC *server = tmp->data;
if (server->connrec->ircnet != NULL &&
strcmp(server->connrec->ircnet, ircnet) == 0) return server;
g_strcasecmp(server->connrec->ircnet, ircnet) == 0) return server;
}
return NULL;

View File

@ -258,7 +258,11 @@ static void init_configfile(void)
if (stat(str, &statbuf) != 0) {
/* ~/.irssi not found, create it. */
if (mkdir(str, 0700) != 0)
g_error("Couldn't create %s/.irssi directory", g_get_home_dir());
g_error(_("Couldn't create %s/.irssi directory"), g_get_home_dir());
} else {
if (!S_ISDIR(statbuf.st_mode)) {
g_error(_("%s/.irssi is not a directory.\nYou should remove it with command: rm ~/.irssi"), g_get_home_dir());
}
}
g_free(str);
@ -266,7 +270,7 @@ static void init_configfile(void)
/* any errors? */
if (config_last_error(mainconfig) != NULL) {
last_error_msg = g_strdup_printf("Ignored errors in configuration file:\n%s",
last_error_msg = g_strdup_printf(_("Ignored errors in configuration file:\n%s"),
config_last_error(mainconfig));
signal_add("irssi init finished", (SIGNAL_FUNC) sig_print_config_error);
}
@ -291,7 +295,7 @@ static void cmd_rehash(const char *data)
if (config_last_error(tempconfig) != NULL) {
/* error */
str = g_strdup_printf("Errors in configuration file:\n%s",
str = g_strdup_printf(_("Errors in configuration file:\n%s"),
config_last_error(tempconfig));
signal_emit("gui dialog", 2, "error", str);
g_free(str);
@ -308,7 +312,16 @@ static void cmd_rehash(const char *data)
static void cmd_save(const char *data)
{
config_write(mainconfig, *data == '\0' ? NULL : data, 0660);
char *str;
if (config_write(mainconfig, *data == '\0' ? NULL : data, 0660) == 0)
return;
/* error */
str = g_strdup_printf(_("Couldn't save configuration file: %s"),
config_last_error(mainconfig));
signal_emit("gui dialog", 2, "error", str);
g_free(str);
}
void settings_init(void)

View File

@ -17,7 +17,7 @@ libfe_common_core_la_SOURCES = \
hilight-text.c \
keyboard.c \
module-formats.c \
nick-hilight.c \
window-activity.c \
printtext.c \
themes.c \
translation.c \

View File

@ -44,7 +44,7 @@ static void sig_autorun(void)
recvlen = read(f, tmpbuf, sizeof(tmpbuf));
ret = line_split(tmpbuf, recvlen, &str, &buffer);
eval_special_string(str, "", active_win->active_server, active_win->active);
if (ret > 0) eval_special_string(str, "", active_win->active_server, active_win->active);
} while (ret > 0);
line_split_free(buffer);

View File

@ -151,7 +151,7 @@ static char *special_history_func(const char *text, void *item, int *free_ret)
static void read_settings(void)
{
window_history = settings_get_bool("toggle_window_history");
window_history = settings_get_bool("window_history");
}
void command_history_init(void)
@ -159,7 +159,7 @@ void command_history_init(void)
settings_add_int("history", "max_textwidget_lines", 1000);
settings_add_int("history", "block_remove_lines", 20);
settings_add_int("history", "max_command_history", 100);
settings_add_bool("history", "toggle_window_history", FALSE);
settings_add_bool("history", "window_history", FALSE);
special_history_func_set(special_history_func);

View File

@ -47,37 +47,34 @@ void fe_server_deinit(void);
void fe_settings_init(void);
void fe_settings_deinit(void);
void nick_hilight_init(void);
void nick_hilight_deinit(void);
void window_activity_init(void);
void window_activity_deinit(void);
void fe_core_commands_init(void);
void fe_core_commands_deinit(void);
void fe_common_core_init(void)
{
settings_add_bool("lookandfeel", "toggle_show_menubar", TRUE);