* progmodes/sh-script.el (sh-font-lock-paren): Handle case
[emacs.git] / doc / misc / erc.texi
blob09e9479449eaba6c752b2fa2ec29e3240924ff0f
1 \input texinfo
2 @c %**start of header
3 @setfilename ../../info/erc
4 @settitle ERC Manual
5 @syncodeindex fn cp
6 @c %**end of header
8 @copying
9 This manual is for ERC version 5.3.
11 Copyright @copyright{} 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
13 @quotation
14 Permission is granted to copy, distribute and/or modify this document
15 under the terms of the GNU Free Documentation License, Version 1.3 or
16 any later version published by the Free Software Foundation; with no
17 Invariant Sections, with the Front-Cover texts being ``A GNU Manual,''
18 and with the Back-Cover Texts as in (a) below.  A copy of the license
19 is included in the section entitled ``GNU Free Documentation License''.
21 (a) The FSF's Back-Cover Text is: ``You have the freedom to copy and
22 modify this GNU manual.  Buying copies from the FSF supports it in
23 developing GNU and promoting software freedom.''
25 All Emacs Lisp code contained in this document may be used, distributed,
26 and modified without restriction.
27 @end quotation
28 @end copying
30 @dircategory Emacs
31 @direntry
32 * ERC: (erc).           Powerful, modular, and extensible IRC client for Emacs.
33 @end direntry
35 @titlepage
36 @title ERC manual
37 @subtitle a full-featured IRC client
38 @subtitle for GNU Emacs and XEmacs
40 @c The following two commands
41 @c start the copyright page.
42 @page
43 @vskip 0pt plus 1filll
44 @insertcopying
45 @end titlepage
47 @contents
49 @ifnottex
50 @node Top, Introduction, (dir), (dir)
51 @comment  node-name,  next,  previous,  up
52 @top ERC
54 @insertcopying
55 @end ifnottex
57 @menu
58 * Introduction::                What is ERC?
59 * Obtaining ERC::               How to get ERC releases and development
60                                   versions.
61 * Installation::                Compiling and installing ERC.
62 * Getting Started::             Quick Start guide to using ERC.
63 * Keystroke Summary::           Keystrokes used in ERC buffers.
64 * Modules::                     Available modules for ERC.
65 * Advanced Usage::              Cool ways of using ERC.
66 * Getting Help and Reporting Bugs::  
67 * History::                     The history of ERC.
68 * Copying::                     The GNU General Public License gives you
69                                   permission to redistribute ERC on
70                                   certain terms; it also explains that
71                                   there is no warranty.
72 * GNU Free Documentation License::  The license for this documentation.
73 * Concept Index::               Search for terms.
75 @detailmenu
76  --- The Detailed Node Listing ---
78 Obtaining ERC
80 * Releases::                    Released versions of ERC.
81 * Development::                 Latest unreleased development changes.
83 Getting Started
85 * Sample Session::              Example of connecting to the #emacs channel
86 * Special Features::            Differences from standalone IRC clients
88 Advanced Usage
90 * Connecting::                  Ways of connecting to an IRC server.
91 * Sample Configuration::        An example configuration file.
92 * Options::                     Options that are available for ERC.
94 @end detailmenu
95 @end menu
97 @node Introduction, Obtaining ERC, Top, Top
98 @comment  node-name,  next,  previous,  up
99 @chapter Introduction
101 ERC is a powerful, modular, and extensible IRC client for Emacs.
103 It comes with the following capabilities enabled by default.
105 @itemize @bullet
106 @item Flood control
107 @item Timestamps
108 @item Join channels automatically
109 @item Buttonize URLs, nicknames, and other text
110 @item Wrap long lines
111 @item Highlight or remove IRC control characters
112 @item Highlight pals, fools, and other keywords
113 @item Detect netsplits
114 @item Complete nicknames and commands in a programmable fashion
115 @item Make displayed lines read-only
116 @item Input history
117 @item Track channel activity in the mode-line
119 @end itemize
121 @node Obtaining ERC, Installation, Introduction, Top
122 @comment  node-name,  next,  previous,  up
123 @chapter Obtaining ERC
125 @menu
126 * Releases::                    Released versions of ERC.
127 * Development::                 Latest unreleased development changes.
128 @end menu
130 Note that some ERC files are not included with Emacs due to copyright or
131 dependency issues.  If desired, they may be found at the following
132 locations, or from your local GNU mirror.
134 @itemize @bullet
135 @item @uref{http://ftp.gnu.org/gnu/erc/erc-5.3-extras.tar.gz}
136 @item @uref{http://ftp.gnu.org/gnu/erc/erc-5.3-extras.zip}
137 @end itemize
139 The rest of this chapter may be skipped if you are using the version of
140 ERC that comes with Emacs.
142 @node Releases, Development, Obtaining ERC, Obtaining ERC
143 @comment  node-name,  next,  previous,  up
144 @section Releases
146 Choose to install a release if you want to minimize risk.
148 Errors are corrected in development first.  User-visible changes will be
149 announced on the @email{erc-discuss@@gnu.org} mailing list.
150 @pxref{Getting Help and Reporting Bugs}.
152 @cindex releases, Debian package
153 @cindex Debian package for ERC
154 Debian users can get ERC via apt-get.  The @file{erc} package is
155 available in the official Debian repository.
157 @cindex releases, from source
158 Alternatively, you can download the latest release from
159 @uref{http://ftp.gnu.org/gnu/erc}, or your local GNU mirror.
161 @node Development,  , Releases, Obtaining ERC
162 @comment  node-name,  next,  previous,  up
163 @section Development
164 @cindex development
166 Choose the development version if you want to live on the bleeding edge
167 of ERC development or try out new features before release.
169 @cindex git version control system, using
170 The git version control system allows you to keep up-to-date with the
171 latest changes to the development version of ERC.  It also allows you
172 to contribute changes (via commits, if you are have developer access to
173 the repository, or via patches, otherwise).  If you would like to
174 contribute to ERC development, it is highly recommended that you use
175 git.
177 If you are new to git, you might find this tutorial helpful:
178 @uref{http://www.kernel.org/pub/software/scm/git/docs/tutorial.html}.
180 Downloading ERC with git and staying up-to-date involves the following
181 steps.
183 @enumerate
184 @item Install git.
186 @itemize @bullet
187 @item Debian and Ubuntu: @kbd{apt-get install git-core}.
188 @item Windows: @uref{http://git.or.cz/gitwiki/WindowsInstall}.
189 @item Other operating systems: download, compile, and install the source
190 from @uref{http://www.kernel.org/pub/software/scm/git/}, or find a git
191 package for your operating system.
192 @end itemize
194 @item Download the ERC development branch.
196 If you have developer access to ERC, do:
198 @example
199 git clone ssh://loginname@@git.sv.gnu.org/srv/git/erc.git
200 @end example
202 otherwise, do:
204 @example
205 git clone git://git.sv.gnu.org/erc.git
206 @end example
208 If you are behind a restrictive firewall, and do not have developer
209 access, then do the following instead:
211 @example
212 git clone http://git.sv.gnu.org/r/erc.git
213 @end example
215 @item List upstream changes that are missing from your local copy.
216 Do this whenever you want to see whether new changes have been committed
217 to ERC.  If you wish, you may skip this step and proceed directly to
218 the ``update'' step.
220 @example
221 # Change to the source directory you are interested in.
222 cd erc
224 # Fetch new changes from the repository, but don't apply them yet
225 git fetch origin
227 # Display log messages for the new changes
228 git log HEAD..origin
229 @end example
231 ``origin'' is git's name for the location where you originally got ERC
232 from.  You can change this location at any time by editing the
233 @file{.git/config} file in the directory where the ERC source was
234 placed.
236 @cindex updating ERC with git
237 @item Update to the latest version by pulling in any missing changes.
239 @example
240 cd erc
241 git pull origin
242 @end example
244 git will show how many files changed, and will provide a visual display
245 for how many lines were changed in each file.
247 @end enumerate
249 There are other ways to interact with the ERC repository.
251 @itemize
252 @item Browse git repo: @uref{http://git.sv.gnu.org/gitweb/?p=erc.git}
253 @item Latest development snapshot: @uref{http://mwolson.org/static/dist/erc-latest.tar.gz}
254 @item Latest development snapshot (zip file): @uref{http://mwolson.org/static/dist/erc-latest.zip}
255 @end itemize
257 The latest development snapshot can lag behind the git repo by as much
258 as 20 minutes, but never more than that.
260 For further information on committing changes to ERC and performing
261 development, please consult
262 @uref{http://emacswiki.org/cgi-bin/wiki/ErcDevelopment}.
265 @node Installation, Getting Started, Obtaining ERC, Top
266 @comment  node-name,  next,  previous,  up
267 @chapter Installation
269 ERC may be compiled and installed on your machine.
271 This section may be skipped if you are using the version of ERC that
272 comes with Emacs.
274 @subsubheading Compilation
276 This is an optional step, since Emacs Lisp source code does not
277 necessarily have to be byte-compiled.  It will yield a speed increase,
278 though.
280 A working copy of Emacs or XEmacs is needed in order to compile ERC.  By
281 default, the program that is installed with the name @command{emacs}
282 will be used.
284 If you want to use the @command{xemacs} binary to perform the
285 compilation, you would need to edit @file{Makefile} in the top-level
286 directory as follows.  You can put either a full path to an Emacs or
287 XEmacs binary or just the command name, as long as it is in the
288 @env{PATH}.
290 @example
291 EMACS    = xemacs
292 SITEFLAG = -no-site-file
293 @end example
295 Running @code{make} should compile the ERC source files in the
296 @file{lisp} directory.
298 @subsubheading Installation
300 ERC may be installed into your file hierarchy by doing the following.
302 Edit the @file{Makefile} file so that @env{ELISPDIR} points to where you
303 want the source and compiled ERC files to be installed and
304 @env{INFODIR} indicates where to put the ERC manual.  Of course, you
305 will want to edit @env{EMACS} and @env{SITEFLAG} as shown in the
306 Compilation section if you are using XEmacs.
308 If you are installing ERC on a Debian system, you might want to change
309 the value of @env{INSTALLINFO} as specified in @file{Makefile}.
311 Run @code{make} as a normal user.
313 Run @code{make install} as the root user if you have chosen installation
314 locations that require this.
317 @node Getting Started, Keystroke Summary, Installation, Top
318 @comment  node-name,  next,  previous,  up
319 @chapter Getting Started
320 @cindex settings
322 To use ERC, add the directory containing its files to your
323 @code{load-path} variable, in your @file{.emacs} file.  Then, load ERC
324 itself.  An example follows.
326 @lisp
327 (require 'erc)
328 @end lisp
330 Once ERC is loaded, the command @kbd{M-x erc} will start ERC and
331 prompt for the server to connect to.
333 If you want to place ERC settings in their own file, you can place them
334 in @file{~/.emacs.d/.ercrc.el}, creating it if necessary.
336 If you would rather use the Customize interface to change how ERC works,
337 do @kbd{M-x customize-group RET erc RET}.  In particular, ERC comes with
338 lots of modules that may be enabled or disabled; to select which ones
339 you want, do @kbd{M-x customize-variable RET erc-modules RET}.
341 @menu
342 * Sample Session::              Example of connecting to the #emacs channel
343 * Special Features::            Differences from standalone IRC clients
344 @end menu
346 @node Sample Session, Special Features, Getting Started, Getting Started
347 @comment  node-name,  next,  previous,  up
348 @section Sample Session
350 This is an example ERC session which shows how to connect to the #emacs
351 channel on Freenode.  Another IRC channel on Freenode that may be of
352 interest is #erc, which is a channel where ERC users and developers hang
353 out.
355 @itemize @bullet
357 @item Connect to Freenode
359 Run @kbd{M-x erc}.  Use ``irc.freenode.net'' as the IRC server, ``6667''
360 as the port, and choose a nickname.
362 @item Get used to the interface
364 Switch to the ``irc.freenode.net:6667'' buffer, if you're not already
365 there.  You will see first some messages about checking for ident, and
366 then a bunch of other messages that describe the current IRC server.
368 @item Join the #emacs channel
370 In that buffer, type ``/join SPC #emacs'' and hit @kbd{RET}.  Depending
371 on how you've set up ERC, either a new buffer for ``#emacs'' will be
372 displayed, or a new buffer called ``#emacs'' will be created in the
373 background.  If the latter, switch to the ``#emacs'' buffer.  You will
374 see the channel topic and a list of the people who are currently on the
375 channel.
377 @item Register your nickname with Freenode
379 If you would like to be able to talk with people privately on the
380 Freenode network, you will have to ``register'' your nickname.  To do
381 so, switch to the ``irc.freenode.net:6667'' buffer and type ``/msg
382 NickServ register <password>'', replacing ``<password>'' with your
383 desired password.  It should tell you that the operation was successful.
385 @item Talk to people in the channel
387 If you switch back to the ``#emacs'' buffer, you can type a message, and
388 everyone on the channel will see it.
390 @item Open a query buffer to talk to someone
392 If you want to talk with someone in private (this should usually not be
393 done for technical help, only for personal questions), type ``/query
394 <nick>'', replacing ``<nick>'' with the nickname of the person you would
395 like to talk to.  Depending on how ERC is set up, you will either see a
396 new buffer with the name of the person, or such a buffer will be created
397 in the background and you will have to switch to it.  Begin typing
398 messages, and you will be able to have a conversation.
400 Note that if the other person is not registered, you will not be able to
401 talk with them.
403 @end itemize
405 @node Special Features, , Sample Session, Getting Started
406 @comment  node-name,  next,  previous,  up
407 @section Special Features
409 ERC has some features that distinguish it from some IRC clients.
411 @itemize @bullet
413 @item multiple channels and multiple servers
415 Every channel is put in a separate buffer.  Several IRC servers may be
416 connected to at the same time.
418 @cindex query buffers
419 @item private message separation
421 Private conversations are treated as channels, and are put into separate
422 buffers in Emacs.  We call these ``query buffers''.
424 @item highlighting
426 Some occurrences of words can be highlighted, which makes it easier to
427 track different kinds of conversations.
429 @item notification
431 ERC can notify you that certain users are online.
433 @item channel tracking
435 Channels can be hidden and conversation continue in the background.  You
436 are notified when something is said in such a channel that is not
437 currently visible.  This makes it easy to get Real Work done while still
438 maintaining an IRC presence.
440 @item nick completion
442 ERC can complete words upon hitting @kbd{TAB}, which eases the writing
443 of nicknames in messages.
445 @cindex history ring
446 @item history
448 Past actions are kept in history rings for future use.  To navigate a
449 history ring, hit @kbd{M-p} to go backwards and @kbd{M-n} to go
450 forwards.
452 @item multiple languages
454 Different channels and servers may have different language encodings.
456 In addition, it is possible to translate the messages that ERC uses into
457 multiple languages.  Please contact the developers of ERC at
458 @email{erc-discuss@@gnu.org} if you are interested in helping with the
459 translation effort.
461 @item user scripting
463 Users can load scripts (e.g. auto greeting scripts) when ERC starts up.
465 It is also possible to make custom IRC commands, if you know a little
466 Emacs Lisp.  Just make an Emacs Lisp function and call it
467 @code{erc-cmd-NEWCOMMAND}, where @code{NEWCOMMAND} is the name of the
468 new command in capital letters.
470 @item auto reconnect
472 If the connection goes away at some point, ERC will try to reconnect
473 automatically.  If it fails to reconnect, and you want to try to
474 manually reestablish the connection at some later point, switch to an
475 ERC  buffer and run the @code{/RECONNECT} command.
477 @end itemize
480 @node Keystroke Summary, Modules, Getting Started, Top
481 @comment  node-name,  next,  previous,  up
482 @chapter Keys Used in ERC
483 @cindex keystrokes
485 This is a summary of keystrokes available in every ERC buffer.
487 @table @kbd
489 @item C-a or <home> (`erc-bol')
490 Go to beginning of line or end of prompt.
492 @item RET (`erc-send-current-line')
493 Send the current line
495 @item TAB (`erc-complete-word')
496 If at prompt, complete the current word.
497 Otherwise, move to the next link or button.
499 @item M-TAB (`ispell-complete-word')
500 Complete the given word, using ispell.
502 @item C-c C-a (`erc-bol')
503 Go to beginning of line or end of prompt.
505 @item C-c C-b (`erc-iswitchb')
506 Use `iswitchb-read-buffer' to prompt for a ERC buffer to switch to.
508 @item C-c C-c (`erc-toggle-interpret-controls')
509 Toggle interpretation of control sequences in messages.
511 @item C-c C-d (`erc-input-action')
512 Interactively input a user action and send it to IRC.
514 @item C-c C-e (`erc-toggle-ctcp-autoresponse')
515 Toggle automatic CTCP replies (like VERSION and PING).
517 @item C-c C-f (`erc-toggle-flood-control')
518 Toggle use of flood control on sent messages.
520 @item C-c TAB (`erc-invite-only-mode')
521 Turn on the invite only mode (+i) for the current channel.
523 @item C-c C-j (`erc-join-channel')
524 Join channel.  If point is at the beginning of a channel name, use that
525 as default.
527 @item C-c C-k (`erc-go-to-log-matches-buffer')
528 Interactively open an erc-log-matches buffer
530 @item C-c C-l (`erc-save-buffer-in-logs')
531 Append buffer contents to the log file, if logging is enabled.
533 @item C-c C-n (`erc-channel-names')
534 Run "/names #channel" in the current channel.
536 @item C-c C-o (`erc-get-channel-mode-from-keypress')
537 Read a key sequence and call the corresponding channel mode function.
538 After doing @kbd{C-c C-o}, type in a channel mode letter.
540 @kbd{C-g} means quit.
541 @kbd{RET} lets you type more than one mode at a time.
542 If @kbd{l} is pressed, @code{erc-set-channel-limit} gets called.
543 If @kbd{k} is pressed, @code{erc-set-channel-key} gets called.
544 Anything else will be sent to `erc-toggle-channel-mode'.
546 @item C-c C-p (`erc-part-from-channel')
547 Part from the current channel and prompt for a reason.
549 @item C-c C-q (`erc-quit-server')
550 Disconnect from current server after prompting for reason.
552 @item C-c C-r (`erc-remove-text-properties-region')
553 Clears the region (start,end) in object from all colors, etc.
555 @item C-c C-t (`erc-set-topic')
556 Prompt for a topic for the current channel.
558 @item C-c C-u (`erc-kill-input')
559 Kill current input line using `erc-bol' followed by `kill-line'.
561 @end table
564 @node Modules, Advanced Usage, Keystroke Summary, Top
565 @comment  node-name,  next,  previous,  up
566 @chapter Modules
567 @cindex modules
569 One way to add functionality to ERC is to customize which of its many
570 modules are loaded.
572 There is a spiffy customize interface, which may be reached by typing
573 @kbd{M-x customize-option erc-modules RET}.  Alternatively, set
574 @code{erc-modules} manually and then call @code{erc-update-modules}.
576 The following is a list of available modules.
578 @table @code
580 @cindex modules, autoaway
581 @item autoaway
582 Set away status automatically
584 @cindex modules, autojoin
585 @item autojoin
586 Join channels automatically
588 @cindex modules, bbdb
589 @item bbdb
590 Integrate with the Big Brother Database
592 @cindex modules, button
593 @item button
594 Buttonize URLs, nicknames, and other text
596 @cindex modules, capab-identify
597 @item capab-identify
598 Mark unidentified users on freenode and other servers supporting CAPAB.
600 @cindex modules, completion
601 @cindex modules, pcomplete
602 @item completion (aka pcomplete)
603 Complete nicknames and commands (programmable)
605 @cindex modules, fill
606 @item fill
607 Wrap long lines
609 @cindex modules, hecomplete
610 @item hecomplete
611 Complete nicknames and commands (old).  This is the old module---you
612 might prefer the ``completion'' module instead.
614 @cindex modules, identd
615 @item identd
616 Launch an identd server on port 8113
618 @cindex modules, irccontrols
619 @item irccontrols
620 Highlight or remove IRC control characters
622 @cindex modules, log
623 @item log
624 Save buffers in logs
626 @cindex modules, match
627 @item match
628 Highlight pals, fools, and other keywords
630 @cindex modules, menu
631 @item menu
632 Display a menu in ERC buffers
634 @cindex modules, netsplit
635 @item netsplit
636 Detect netsplits
638 @cindex modules, noncommands
639 @item noncommands
640 Don't display non-IRC commands after evaluation
642 @cindex modules, notify
643 @item notify
644 Notify when the online status of certain users changes
646 @cindex modules, page
647 @item page
648 Process CTCP PAGE requests from IRC
650 @cindex modules, readonly
651 @item readonly
652 Make displayed lines read-only
654 @cindex modules, replace
655 @item replace
656 Replace text in messages
658 @cindex modules, ring
659 @item ring
660 Enable an input history
662 @cindex modules, scrolltobottom
663 @item scrolltobottom
664 Scroll to the bottom of the buffer
666 @cindex modules, services
667 @item services
668 Identify to Nickserv (IRC Services) automatically
670 @cindex modules, smiley
671 @item smiley
672 Convert smileys to pretty icons
674 @cindex modules, sound
675 @item sound
676 Play sounds when you receive CTCP SOUND requests
678 @cindex modules, spelling
679 @item spelling
680 Check spelling of messages
682 @cindex modules, stamp
683 @item stamp
684 Add timestamps to messages
686 @cindex modules, track
687 @item track
688 Track channel activity in the mode-line
690 @cindex modules, truncate
691 @item truncate
692 Truncate buffers to a certain size
694 @cindex modules, unmorse
695 @item unmorse
696 Translate morse code in messages
698 @end table
700 @c PRE5_4: Document every option of every module in its own subnode
703 @node Advanced Usage, Getting Help and Reporting Bugs, Modules, Top
704 @comment  node-name,  next,  previous,  up
705 @chapter Advanced Usage
706 @cindex advanced topics
708 @menu
709 * Connecting::                  Ways of connecting to an IRC server.
710 * Sample Configuration::        An example configuration file.
711 * Options::                     Options that are available for ERC.
712 @end menu
714 @node Connecting, Sample Configuration, Advanced Usage, Advanced Usage
715 @comment  node-name,  next,  previous,  up
716 @section Connecting to an IRC Server
717 @cindex connecting
719 The easiest way to connect to an IRC server is to call @kbd{M-x erc}.
720 If you want to assign this function to a keystroke, the following will
721 help you figure out its parameters.
723 @defun erc
724 Select connection parameters and run ERC.
725 Non-interactively, it takes the following keyword arguments.
727 @itemize @bullet
728 @item @var{server}
729 @item @var{port}
730 @item @var{nick}
731 @item @var{password}
732 @item @var{full-name}
733 @end itemize
735 That is, if called with the following arguments, @var{server} and
736 @var{full-name} will be set to those values, whereas
737 @code{erc-compute-port}, @code{erc-compute-nick} and
738 @code{erc-compute-full-name} will be invoked for the values of the other
739 parameters.
741 @example
742 (erc :server "irc.freenode.net" :full-name "Harry S Truman")
743 @end example
744 @end defun
746 @subheading Server
748 @defun erc-compute-server &optional server
749 Return an IRC server name.
751 This tries a number of increasingly more default methods until a non-nil
752 value is found.
754 @itemize @bullet
755 @item @var{server} (the argument passed to this function)
756 @item The @code{erc-server} option
757 @item The value of the IRCSERVER environment variable
758 @item The @code{erc-default-server} variable
759 @end itemize
761 @end defun
763 @defopt erc-server nil
764 IRC server to use if one is not provided.
765 @end defopt
767 @subheading Port
769 @defun erc-compute-port &optional port
770 Return a port for an IRC server.
772 This tries a number of increasingly more default methods until a non-nil
773 value is found.
775 @itemize @bullet
776 @item @var{port} (the argument passed to this function)
777 @item The @code{erc-port} option
778 @item The @code{erc-default-port} variable
779 @end itemize
781 @end defun
783 @defopt erc-port
784 IRC port to use if not specified.
786 This can be either a string or a number.
787 @end defopt
789 @subheading Nick
791 @defun erc-compute-nick &optional nick
792 Return user's IRC nick.
794 This tries a number of increasingly more default methods until a
795 non-nil value is found.
797 @itemize
798 @item @var{nick} (the argument passed to this function)
799 @item The @code{erc-nick} option
800 @item The value of the IRCNICK environment variable
801 @item The result from the @code{user-login-name} function
802 @end itemize
804 @end defun
806 @defopt erc-nick
807 Nickname to use if one is not provided.
809 This can be either a string, or a list of strings.
810 In the latter case, if the first nick in the list is already in use,
811 other nicks are tried in the list order.
812 @end defopt
814 @defopt erc-nick-uniquifier
815 The string to append to the nick if it is already in use.
816 @end defopt
818 @defopt erc-try-new-nick-p
819 If the nickname you chose isn't available, and this option is non-nil,
820 ERC should automatically attempt to connect with another nickname.
822 You can manually set another nickname with the /NICK command.
823 @end defopt
825 @subheading Full name
827 @defun erc-compute-full-name &optional full-name
828 Return user's full name.
830 This tries a number of increasingly more default methods until a
831 non-nil value is found.
833 @itemize @bullet
834 @item @var{full-name} (the argument passed to this function)
835 @item The @code{erc-user-full-name} option
836 @item The value of the IRCNAME environment variable
837 @item The result from the @code{user-full-name} function
838 @end itemize
840 @end defun
842 @defopt erc-user-full-name
843 User full name.
845 This can be either a string or a function to call.
846 @end defopt
848 @node Sample Configuration, Options, Connecting, Advanced Usage
849 @comment  node-name,  next,  previous,  up
850 @section Sample Configuration
851 @cindex configuration, sample
853 Here is an example of configuration settings for ERC.  This can go into
854 your Emacs configuration file.  Everything after the @code{(require
855 'erc)} command can optionally go into @file{~/.emacs.d/.ercrc.el}.
857 @lisp
858 ;;; Sample ERC configuration
860 ;; Add the ERC directory to load path -- you don't need this if you are
861 ;; using the version of ERC that comes with Emacs
862 (add-to-list 'load-path "~/elisp/erc")
864 ;; Load ERC
865 (require 'erc)
867 ;; Load authentication info from an external source.  Put sensitive
868 ;; passwords and the like in here.
869 (load "~/.emacs.d/.erc-auth")
871 ;; This is an example of how to make a new command.  Type "/uptime" to
872 ;; use it.
873 (defun erc-cmd-UPTIME (&rest ignore)
874   "Display the uptime of the system, as well as some load-related
875 stuff, to the current ERC buffer."
876   (let ((uname-output
877          (replace-regexp-in-string
878           ", load average: " "] @{Load average@} ["
879           ;; Collapse spaces, remove
880           (replace-regexp-in-string
881            " +" " "
882            ;; Remove beginning and trailing whitespace
883            (replace-regexp-in-string
884             "^ +\\|[ \n]+$" ""
885             (shell-command-to-string "uptime"))))))
886     (erc-send-message
887      (concat "@{Uptime@} [" uname-output "]"))))
889 ;; This causes ERC to connect to the Freenode network upon hitting
890 ;; C-c e f.  Replace MYNICK with your IRC nick.
891 (global-set-key "\C-cef" (lambda () (interactive)
892                            (erc :server "irc.freenode.net" :port "6667"
893                                 :nick "MYNICK")))
895 ;; This causes ERC to connect to the IRC server on your own machine (if
896 ;; you have one) upon hitting C-c e b.  Replace MYNICK with your IRC
897 ;; nick.  Often, people like to run bitlbee (http://bitlbee.org/) as an
898 ;; AIM/Jabber/MSN to IRC gateway, so that they can use ERC to chat with
899 ;; people on those networks.
900 (global-set-key "\C-ceb" (lambda () (interactive)
901                            (erc :server "localhost" :port "6667"
902                                 :nick "MYNICK")))
904 ;; Make C-c RET (or C-c C-RET) send messages instead of RET. This has
905 ;; been commented out to avoid confusing new users.
906 ;; (define-key erc-mode-map (kbd "RET") nil)
907 ;; (define-key erc-mode-map (kbd "C-c RET") 'erc-send-current-line)
908 ;; (define-key erc-mode-map (kbd "C-c C-RET") 'erc-send-current-line)
910 ;;; Options
912 ;; Join the #emacs and #erc channels whenever connecting to Freenode.
913 (setq erc-autojoin-channels-alist '(("freenode.net" "#emacs" "#erc")))
915 ;; Interpret mIRC-style color commands in IRC chats
916 (setq erc-interpret-mirc-color t)
918 ;; The following are commented out by default, but users of other
919 ;; non-Emacs IRC clients might find them useful.
920 ;; Kill buffers for channels after /part
921 ;; (setq erc-kill-buffer-on-part t)
922 ;; Kill buffers for private queries after quitting the server
923 ;; (setq erc-kill-queries-on-quit t)
924 ;; Kill buffers for server messages after quitting the server
925 ;; (setq erc-kill-server-buffer-on-quit t)
926 @end lisp
928 @node Options, , Sample Configuration, Advanced Usage
929 @comment  node-name,  next,  previous,  up
930 @section Options
931 @cindex options
933 @c PRE5_4: (Node) Document every ERC option (module options go in
934 @c previous chapter)
936 This section has not yet been written.  For now, the easiest way to
937 check out the available options for ERC is to do
938 @kbd{M-x customize-group erc RET}.
941 @node Getting Help and Reporting Bugs, History, Advanced Usage, Top
942 @comment  node-name,  next,  previous,  up
943 @chapter Getting Help and Reporting Bugs
944 @cindex help, getting
945 @cindex bugs, reporting
947 After you have read this guide, if you still have questions about ERC,
948 or if you have bugs to report, there are several places you can go.
950 @itemize @bullet
952 @item
953 @uref{http://www.emacswiki.org/cgi-bin/wiki/ERC} is the
954 emacswiki.org page for ERC.  Anyone may add tips, hints, or bug
955 descriptions to it.
957 @item
958 There are several mailing lists for ERC.  To subscribe, visit
959 @uref{http://savannah.gnu.org/mail/?group=erc}.
961 The mailing lists are also available on Gmane.
962 (@url{http://gmane.org/}).  Gmane provides additional methods for
963 accessing the mailing lists, adding content to them, and searching them.
965 @enumerate
966 @item gmane.emacs.erc.announce: Announcements
968 @item gmane.emacs.erc.discuss: General discussion
970 @item gmane.emacs.erc.cvs: Log messages for changes to the ERC source code
972 @end enumerate
974 @item
975 You can visit the IRC Freenode channel @samp{#emacs}. Many of the
976 contributors are frequently around and willing to answer your
977 questions.
979 @end itemize
982 @node History, Copying, Getting Help and Reporting Bugs, Top
983 @comment  node-name,  next,  previous,  up
984 @chapter History
985 @cindex history, of ERC
987 ERC was originally written by Alexander L. Belikoff
988 @email{abel@@bfr.co.il} and Sergey Berezin
989 @email{sergey.berezin@@cs.cmu.edu}.  They stopped development around
990 December 1999.  Their last released version was ERC 2.0.
992 P.S.: If one of the original developers of ERC reads this, we'd like to
993 receive additional information for this file and hear comments in
994 general.
996 @itemize
997 @item 2001
999 In June 2001, Mario Lang @email{mlang@@delysid.org} and Alex Schroeder
1000 @email{alex@@gnu.org} took over development and created a ERC Project at
1001 @uref{http://sourceforge.net/projects/erc}.
1003 In reaction to a mail about the new ERC development effort, Sergey
1004 Berezin said, ``First of all, I'm glad that my version of ERC is being
1005 used out there.  The thing is, I do not have free time and enough
1006 incentive anymore to work on ERC, so I would be happy if you guys take
1007 over the project entirely.''
1009 So we happily hacked away on ERC, and soon after (September 2001)
1010 released the next "stable" version, 2.1.
1012 Most of the development of the new ERC happened on #emacs on
1013 irc.openprojects.net.  Over time, many people contributed code, ideas,
1014 bugfixes, and a lot of alpha/beta/gamma testing.
1016 See the @file{CREDITS} file for a list of contributors.
1018 @item 2003
1020 ERC 3.0 was released.
1022 @item 2004
1024 ERC 4.0 was released.
1026 @item 2005
1028 ERC 5.0 was released.  Michael Olson @email{mwolson@@gnu.org} became
1029 the release manager and eventually the maintainer.
1031 After some discussion between him and the Emacs developers, it was
1032 decided to include ERC in Emacs.
1034 @item 2006
1036 ERC 5.1 was released.  It was subsequently included in Emacs 22.
1038 ERC became an official GNU project, and development moved to
1039 @uref{http://sv.gnu.org/projects/erc}.  We switched to using GNU Arch as
1040 our revision control system.  Our mailing list address changed as well.
1042 @item 2007
1044 We switched to using git for our version control system.
1046 @end itemize
1048 @node Copying, GNU Free Documentation License, History, Top
1049 @comment  node-name,  next,  previous,  up
1050 @include gpl.texi
1052 @node GNU Free Documentation License, Concept Index, Copying, Top
1053 @comment  node-name,  next,  previous,  up
1054 @include doclicense.texi
1056 @node Concept Index,  , GNU Free Documentation License, Top
1057 @comment  node-name,  next,  previous,  up
1058 @unnumbered Index
1060 @printindex cp
1062 @bye
1064 @ignore
1065    arch-tag: cf9cfaff-fc12-4297-ad15-ec2493002b1e
1066 @end ignore