WeeChat

From Gentoo Wiki
Jump to: navigation, search

WeeChat is a light, extensible, actively maintained, well documented, highly featured text-mode IRC client. WeeChat natively runs through ncurses for the text-mode interface, however for user convenience many 'remote' interfaces (GUIs) are available to relay WeeChat data to more accessible mediums (Android phones, Web interfaces, X GUIs, and more).

Installation

USE flags

USE flags for net-irc/weechat Portable and multi-interface IRC client

alias Enable plugin for alias control. local
buflist Enable buflist plugin. local
charset Enable encoding conversions. local
doc Add extra documentation (API, Javadoc, etc). It is recommended to enable per package instead of globally global
exec Enable exec plugin. local
fifo Enable FIFO support (sh pipes). local
guile Add support for the guile Scheme interpreter global
irc Enable IRC protocol support. local
logger Enable support for logging. local
lua Enable Lua scripting support global
nls Add Native Language Support (using gettext - GNU locale utilities) global
perl Add optional support/bindings for the Perl language global
python Add optional support/bindings for the Python language global
relay Enable relay plugin (experimental) local
ruby Add support/bindings for the Ruby language global
scripts Build infrastructure for scripting. local
spell Add dictionary support global
ssl Add support for Secure Socket Layer connections global
tcl Add support the Tcl language global
test Workaround to pull in packages needed to run with FEATURES=test. Portage-2.1.2 handles this internally, so don't set it in make.conf/package.use anymore global
trigger Enable trigger plugin. local
xfer Enable xfer plugin support. local

Emerge

root #emerge --ask net-irc/weechat

Configuration

An excellent quick start guide can be found on WeeChat's website. The official guide should be followed for the most up to date configuration instructions. Head over there and read the guide. When finished return here if necessary for further instructions.

Auto-join channels

After making it through step 7 in the WeeChat quick start guide Freenode should be added as the server. Custom channels can be automatically joined each time WeeChat is opened by running the following command inside the WeeChat client:

/set irc.server.freenode.autojoin "#gentoo,#gentoo-chat"

This should add the #gentoo and #gentoo-chat channels to the auto-join list each time weechat starts. Add or subtract more more channels to the comma separated list as desired. Everyone has their own channels interests!

Adding a relay

In order to use remote interfaces, WeeChat needs to be configured as a relay.

/relay add weechat <port_number>

Next set the password for the relay:

/set relay.network.password <password>

Remote interfaces

The following remote interfaces are available:

  • Glowing Bear - A web frontend for WeeChat. See the Glowing Bear Guide for hosting Glowing Bear on Gentoo.
  • QWeeChat - A Qt interface for WeeChat.
  • WeeChat Android - Only works on Android phones. Simply download the application from the Google Play Store and get started!
  • Emacs - A weird emacs thing.
  • WeeCloud - A WeeChat client written in javascript.

Each remote interface has a unique setup. Not all of the clients available in the list above may be operational. Glowing Bear is probably the most tested of the bunch. When in doubt try Glowing Bear first.

Plugins

Plugins for WeeChat can be added and removed via USE flags. See the USE flags section above for a list of available plugins.

Usage

It is common for many text-mode IRC client users to run the clients on a system that is always on always connected to the internet. This make it possible to never miss a mention or a message. Like most command-line programs, weechat will run all the time if opened in a screen or a tmux session which is then detached. This is currently the ideal method for staying connected to IRC networks continuously.

screen

Open screen using the following command:

user $screen -t weechat

After weechat is configured press Ctrl+a to enter Command Mode and then d to detach from the screen session. It can be re-attached to later by running:

user $screen -ls

To list the currently running sessions and then entering:

user $screen -r <session>

Where <session> is a weird, crazy string.

For additional information on how to use screen visit the screen article.

tmux

Simply open tmux using the following command:

user $tmux new -s weechat

By default a green status stripe should be visible near the bottom of the terminal. This is an indicator that tmux is running. Start weechat:

user $weechat

After weechat has been configured, disconnect from the session by using Ctrl+b and then press d to detach.

In order to reconnect to the tmux session that is running (which was titled "Template:Weechat") issue:

user $tmux a -t weechat

For additional information on how to use tmux visit the tmux article.

Removal

Unmerge

root #emerge --ask --depclean --verbose net-irc/weechat

Configuration and logs

After unmerging, for a full clean-up, be sure to remove old logs and individual user configuration from their default location in each weechat user's home directory:

user $rm -rf ~/.weechat

See also

  • Irssi - Another text mode IRC client.

External resources