Scroll to navigation

localslackirc(1) General Commands Manual localslackirc(1)

NAME

localslackirc - Creates an IRC server running locally, which acts as a gateway to slack for one user.

SYNOPSIS

localslackirc [OPTIONS]

DESCRIPTION

This command starts an IRC server running on 127.0.0.1:9007 which acts as a gateway to slack for one user.
To connect to multiple instances it is necessary to run multiple instances of this software.

Options:

Show the help message and exit.
Show the version and exit.
Set the port number. The default is 9007.
Set the IP (Ipv4 only) address to listen to. The default is 127.0.0.1.
Set the token file. The default is ~/.localslackirc.
Set the cookie file. This is only used on slack, and is only useful if your token starts with "xoxc".
Don't display userlist in the IRC client.
Automatically join all remote channels.
Allow listening on addresses that do not start with 127.*
This is potentially dangerous.
Where to create files for automatic downloads. It defaults to /tmp.
The directory must exist and be writeable. Files will automatically be downloaded in it.
No cleaning is automatically performed on it by localslackirc.
Maximum amount of lines in a formatted text to send to the client rather than store in a file.
When people send logs or otherwise long text content as formatted text, the end result is usually hardly readable in IRC, having the username of the sender and the time in each line.
This option sets a limit for formatted content to be sent as text.
When the limit is exceeded, the formatted text will be stored as a .txt file instead and its URL will be shown in the IRC client.
The files will be saved in the path specified by "downloads directory".
The files are not automatically removed.
Setting to 0 (the default) will send everything to the client and create no text files.
Path to the file keeping the status. When this is set, it allows for the history to be loaded on start.
Comma separated list of nicknames and channels that are prevented from using general mentions (@here, @channel, @everyone, and the likes).
Since some people are greatly abusing the feature, this is to make them less annoying.
Their messages aren't blocked and are shown as "yelling MESSAGE", but the nickname of the user won't be injected in the message, so the IRC client won't create a notification.
The channels must begin with #.
The threads created from a silenced channel will also be silenced.
Enables debugging logs.
Instead of using localslackirc as ident for syslog, this appends a custom string, separated by a -.
This is useful when running several instances, to be able to distinguish the logs.
The default .service file uses this. Of course journald keeps track of the services but this makes it easier to have the information on text dumps or other logging daemons such as rsyslog.
Comma separated list of channels to ignore and not automatically join on IRC.
It is ignored unless autojoin is set.
If a channel is in this list, the IRC client will not automatically join it, but on slack you will still be inside the channel
This is useful to avoid off topic channels in which coworkers who can't take a hint keep re-inviting.
The ignored channels can be joined again if needed, with a /join #channel command. However the conversation history will not be fetched.
For channel names containing non ascii characters, their ascii representation needs to be used. Use /list to see which that is.

TOKEN

The access token is (unless specified otherwise) located in ~/.localslackirc, for information on how to obtain your token, check the README file.

ENVIRONMENT

The following environment variables are used. They override command line settings. The alternatives to switches must contain "true" to work.

Alternative to --cookiefile
Alternative to --downloads-directory
Alternative to --formatted-max-lines
Alternative to --port
Alternative to --tokenfile
If running as root, this is the name of the user to switch to. If this is not specified, "nobody" will be used.
This is very useful to start localslackirc as a service and configure which user to use in the configuration file.
Alternative to --ip
Alternative to --override
Path to the status file
Alternative to --autojoin
Alternative to --nouserlist
Alternative to --debug
Alternative to --log-suffix
Alternative to --ignored-channels
Alternative to --silenced-yellers

Additional IRC commands

Some commands are added, to use some additional features that are present in slack but not IRC.

/sendfile destination /path/to/file
Sends the specified file to destination.
The destination can be a user or a channel, in which case it must begin with #.
/annoy user [duration]
The indicated user will be annoyed.
This means that whenever a typing event is received from that user, on any channel, a type event on the same channel will be sent back, making the user think you are about to write something too.
duration is the duration of the annoyance in minutes. It defaults to 10.

WEB

https://github.com/ltworf/localslackirc

AUTHOR

Salvo "LtWorf" Tomaselli <tiposchi@tiscali.it>
June 15, 2022 IRC gateway for slack