glirc: Console IRC client

This is a package candidate release! Here you can preview how this package release will appear once published to the main package index (which can be accomplished via the 'maintain' link below). Please note that once a package has been published to the main package index it cannot be undone! Please consult the package uploading documentation for more information.

[maintain] [Publish]


Console IRC client

glirc is a console IRC client with an emphasis on providing dynamic views into the model of your IRC connections.

Documentation Wiki

[Skip to Readme]


Versions 2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9, 2.10, 2.11, 2.12, 2.13, 2.14, 2.15, 2.16, 2.17, 2.18, 2.19, 2.20, 2.20.1,, 2.20.2,, 2.20.3, 2.20.4, 2.20.5, 2.20.6, 2.21, 2.21.1, 2.22, 2.23, 2.23, 2.24, 2.25, 2.26, 2.27, 2.28, 2.29, 2.30, 2.31, 2.32, 2.33, 2.33.1, 2.34, 2.35, 2.36, 2.37, 2.38, 2.39,, 2.40, 2.40.1
Change log
Dependencies async (>=2.1 && <2.2), attoparsec (>=0.13 && <0.14), base (>=4.9 && <4.11), base64-bytestring (>= && <1.1), bytestring (>=0.10.8 && <0.11), config-schema (>=0.4 && <0.6), config-value (>=0.6 && <0.7), containers (>=0.5.7 && <0.6), directory (>=1.2.6 && <1.4), filepath (>=1.4.1 && <1.5), free (>=4.12 && <4.13), gitrev (>=1.2 && <1.4), glirc, hashable (>=1.2.4 && <1.3), hookup (>=0.1 && <0.2), HsOpenSSL (>=0.11 && <0.12), irc-core (>=2.3 && <2.4), kan-extensions (>=5.0 && <5.1), lens (>=4.14 && <4.16), network (>=2.6.2 && <2.7), process (>=1.4.2 && <1.7), regex-tdfa (>=1.2 && <1.3), semigroupoids (>=5.1 && <5.3), socks (>=0.5.5 && <0.6), split (>=0.2 && <0.3), stm (>=2.4 && <2.5), template-haskell (>=2.11 && <2.13), text (>=1.2.2 && <1.3), time (>=1.6 && <1.9), transformers (>=0.5.2 && <0.6), unix (>=2.7 && <2.8), unordered-containers (>=0.2.7 && <0.3), vector (>=0.11 && <0.13), vty (>=5.11.1 && <5.16) [details]
License ISC
Copyright 2016,2017 Eric Mertens
Author Eric Mertens
Category Network
Home page
Bug tracker
Source repo head: git clone git:// -b v2
Uploaded by EricMertens at 2017-07-15T15:28:34Z



Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Readme for glirc-2.23

[back to package description]

GLIRC - Advanced Console IRC Client

Wiki Documentation


glirc uses recent versions of packages, make sure you package databases are up-to-date:

$ cabal update # if you're using cabal
$ stack update # if you're using stack

To install the latest version from Hackage using cabal-install:

$ cabal install glirc

Building with cabal-install from source checkout

$ cabal install --dep
$ cabal build

Building with stack

$ stack init --resolver=lts-8 --solver
$ stack build

Note that if you're using a nightly resolver that you'll need to work around a bug in stack by manually installing alex and happy.

Client Features


  -c PATH  --config=PATH  Configuration file path
  -!       --noconnect    Disable autoconnecting
  -h       --help         Show help
  -v       --version      Show version

Environment variables

USER=<default nickname and username>
IRCPASSWORD=<your irc password>

Configuration file

A configuration file can currently be used to provide some default values instead of using command line arguments. If any value is missing the default will be used.

The default configuration file path is ~/.config/glirc/config

Relative paths are relative to the home directory.

Learn more about this file format at config-value

-- vim: filetype=config-value
-- Grab the Vim syntax highlighting file from the config-value package

-- Learn more about these settings with `glirc2 --config-format`

-- Defaults used when not specified on command line
  nick:            "yournick"
  username:        "yourusername"
  realname:        "Your real name"
  password:        "IRC server password"
  tls:             yes -- or: yes-insecure or no
                       -- enabling tls automatically uses port 6697
  tls-client-cert: "/path/to/cert.pem"
  tls-client-key:  "/path/to/cert.key"

-- Override the defaults when connecting to specific servers
  * name: "fn"
    hostname:      ""
    sasl-username: "someuser"
    sasl-password: "somepass"
    socks-host:    ""
    socks-port:    8080 -- defaults to 1080

  * name: "example"
    hostname:      ""
    port:          7000 -- override the default port
      * "join #favoritechannel,#otherchannel"
      * "msg mybot another command"

    -- Specify additional certificates beyond the system CAs
    -- relative to home directory
    tls-server-cert: "extra/certificate.pem"

  * name: "wipe"
      * "clear"
      * "znc *status clearbuffer $channel"

  * name: "mysplits"
      * "splits fn:#haskell fn:#haskell-offtopic"

  -- Example use of macro in combination with an extension
  * name: "extra"
      * "extension Lua some-parameter $network $channel"

extra-highlights: ["glirc", "lens"]

   side: left -- try right if you don't like left padding
   width: 13

url-opener: "open" -- This works on macOS, "gnome-open" for GNOME

  * bind: "C-M-b"
    command: "masks b"

  line-marker: yellow
    fg: [10,10,10] -- RGB values for color for timestamps
    bg: blue
    [ cyan, magenta, green, yellow, blue
    , bright-cyan, bright-magenta, bright-green, bright-blue
    , 218,  88,  89, 124, 160, 205, 212, 224 -- reds
    ,  94, 130, 166, 172, 208, 214, 216, 180 -- oranges
    ,  58, 226, 229, 184, 187, 100, 142, 220 -- yellows
    ,  22,  34,  40,  82,  70,  64,  48,  85 -- greens
    ,  25,  27,  33,  39,  51,  80,  81,  75 -- blues
    ,  69,  61,  56,  54, 129,  93,  99, 147 -- purples

Configuration sections:

setting type description
defaults server These settings are used for all connections
servers list of servers These settings are used to override defaults when the hostname matches
palette palette Client color overrides
window-names text Names of windows (typically overridden on non QWERTY layouts)
nick-padding nonnegative integer Nicks are padded until they have the specified length
indent-wrapped-lines nonnegative integer How far to indent lines when they are wrapped
extra-highlights list of text Extra words/nicks to highlight
extensions list of text Filenames of extension to load
url-opener text Command to execute with URL parameter for /url e.g. gnome-open on GNOME or open on macOS
ignores list of text Initial list of nicknames to ignore
activity-bar yes or no Initial setting for visibility of activity bar (default no)
bell-on-mention yes or no Sound terminal bell on transition from not mentioned to mentioned (default no)
macros list of macros User-configurable client commands

Server Settings

setting type description
name text name of server entry, defaults to hostname
hostname text hostname used to connect and to specify the server
port number port number, defaults to 6667 without TLS and 6697 with TLS
nick text or list of text nicknames to try in order
username text server username
realname text real name / GECOS
password text server password
sasl-username text SASL username
sasl-password text SASL password (PLAIN mode)
sasl-ecdsa-key text Path ecdsa private key file (ECDSA-NIST256P-CHALLENGE mode)
tls yes/yes-insecure/no use TLS to connect (insecure mode disables certificate checks)
tls-client-cert text path to TLS client certificate
tls-client-key text path to TLS client key
tls-server-cert text CA certificate to use when validating certificates
tls-ciphers text OpenSSL cipher suite description string
connect-cmds list of text client commands to send upon connection
socks-host text hostname of SOCKS proxy to connect through
socks-port number port number of SOCKS proxy to connect through
chanserv-channels list of text list of channels with chanserv op permission
flood-penalty number cost in seconds per message
flood-threshold number threshold in seconds for burst
message-hooks list of text names of hooks to enable
reconnect-attempts int number of reconnections to attempt on error
autoconnect yes or no automatically connect at client startup
nick-completion default or slack set this to slack to use @ sigils when completing nicks


entry type description
nick-colors list of attr Use for nick highlights
self attr our own nickname(s) outside of mentions
self-highlight attr our own nickname(s) in mentions
time attr timestamp on messages
meta attr metadata (joins/parts/etc.)
sigil attr sigils (+@)
label attr information labels
latency attr latency time
error attr error messages
textbox attr textbox edges (^$)
window-name attr current window name
activity attr activity notification
mention attr mention notification
command attr recognized command
command-prefix attr prefix of known command
command-ready attr recognized command with arguments filled
command-placeholder attr command argument placeholder
window-divider attr the dividing line between split windows
line-marker attr the dividing line for new messages

Text Attributes

Text attributes can be specified either as a single foreground color or section of attributes.




Client commands

Connection commands

Window management

Channel membership

Chat commands

Channel management


Channel information

Window filters



Keyboard Shortcuts

Note that these keybindings are using Emacs syntax. C-a means "hold control and press A". M-a means "hold meta key and press A". On most modern keyboards the Meta key is labeled Alt or Option.

Window navigation


Client settings




The macros configuration section allows you to define sequences of commands. These commands can contain expansions.


Macro Expansions

Variable names and integer indexes can be used when defining commands. Variables are specified with a leading $. For disambiguation a variable name can be surrounded by {}. $channel and ${channel} are equivalent. Default values can be provided following a pipe: ${var|default}.

The arguments to a command will be mapped to integer indexes. The command itself is at index zero.



Enable this hook when using ZNC and the buffextra module in order to reinterpret this module's messages natively in the client.