Skip to content
This repository has been archived by the owner on Jun 9, 2019. It is now read-only.

Poorchop/hexchat-scripts

Repository files navigation

hexchat-scripts

This is the collection of HexChat scripts that I have written. Some of these scripts are unfinished, so use them with caution. Feel free to submit issues but don't expect them to be addressed any time soon. Many of these scripts were made possible with help or with templates from TingPing, Farow, Arnavion, GermainZ, ward, and others.

Scripts in the "old" folder are broken and/or unsupported due to depreciations, API changes, or other similar factors. The mirror of Arnavion's scripts has been moved here.


Move common fserve advertisements to a separate tab

To those coming from mIRC, this is meant to to partially replicate the ad-related functionality of DukeLupus's dlFilter script.

Usage: You only need to modify channels = [] for this script to work. See the script comment if you need instructions on how to add a channel to the filter list.

Untested: This script should theoretically detect DCC spammers and automatically add them to ignore. Since I haven't tested it, expect things to be broken. Currently, it only ignores people trying to repeatedly send the same file within a five second period.

For use with ZNC only!: Detach the current channel with a simple "/detach", eliminating the need to pass a channel name. If you do pass a channel name along with the command, then the specified channel is detached instead as normal.

Format messages from specific users to make them easier to follow

Usage: /follow <nick> /unfollow <nick>

This script requires the Exec plugin, which must be selected from the HexChat installer during installation

Automatically launch a TwitchTV stream via Livestreamer when the corresponding channel is joined in HexChat. Livestreamer must be installed for this script to work correctly.

Usage: Follow the guide for connecting to Twitch chat with HexChat, then join a channel to launch the corresponding stream with Livestreamer.

You can alternately type /livestreamer <streamer> <quality> to manually launch a stream.

This script aggregates all join, part, and quit mesages from a user-defined list of servers and/or channels and places them in a new tab. The name of the channel from where the join/part/quit event originated is displayed before each join/part/quit message.

Usage: You can customize the name of the filter tab by setting tab_name = "" to whatever you like. Place your desired name between the quotes. You can view the available commands for this script by typing /help jptab.

To filter a channel:

  • Make the channel you wish to filter the active tab
  • /jptab add channel

You will see a message that the current activated channel under the current network has been added to the filter list.

To filter an entire network:

  • Click on the network tab OR on any of the channel tabs under the network you wish to filter
  • /jptab add network

You will see a message that the current network has been added to the filter list. All channels under this network will have their join/part/quit messages filtered and moved to the filter tab.

To remove a channel or network filter:

  • Activate the desired channel or network as described above
  • For a channel:
    • /jptab remove channel
  • For a network:
    • /jptab remove network

If executed properly, you will see a message that the channel/network has been removed from the filter list.

To view your current filters:

  • /jptab list filters

This script requires the Do At plugin, which must be selected from the HexChat installer during installation
Python 3 version here

Display website titles for links that are pasted in chat

Plays nicely with get-youtube-video-info.py (some message formatting also taken from that script)

Remove nick change messages from channels and place them in the server tab instead

Inspired by notice2server.pl from the legendary Farow

Colorize a channel name in the channel tree when certain users speak in said channel

Usage: Add nicknames for spying on to nicknames = []. Nicknames should be in quotes and separated by commas:

nicknames = ["nick1", "nick2", "nick3"]

This script is based on the PygLatin Python exercise written by Kate Lockwood:

  • If a word begins with a vowel, "ay" is appended to the end of the word.
  • If a word instead begins with a consonant, the first letter of the word is moved to the end, and the result is appended with "ay".

Usage: /pyg <message>

Move search requests (@find, @search, @seek, etc.) and fserve file requests to a separate tab

To those coming from mIRC, this is meant to to partially replicate the request-related functionality of DukeLupus's dlFilter script.

This script is meant to complement adfilter.py, but they can be used independently of each other.

Usage: You only need to modify channels = [] for this script to work. See the script comment if you need instructions on how to add a channel to the filter list.

Automatically truncate nicknames that are beyond a user-defined length

Usage: See script comment for instructions

Automatically formats TwitchTV emotes with proper capitalization

Use TingPing's twitch.py script for a more comprehensive Twitch experience.

Usage: Emotes are formatted with proper capitalization as you type. This only modifies your text when a TwitchTV IRC channel is in focus. Therefore, this script is essentially a twitch-specific auto-replace tool.

This script also replaces a few emotes with similar unicode characters.

Example: "Hello kappa frankerz" is automatically converted to "Hello Kappa FrankerZ" as you type. This message would subsequently appear to you as "Hello 😏 🐶 " whether it was typed by you or by anyone else in the channel.

If you wish to enable support for subscriber emotes, download [this file] (https://raw.githubusercontent.com/Poorchop/hexchat-scripts/master/twitch-sub-emotes.txt), place it your HexChat addons folder, ensure that [this line] (

allow_sub_emotes = True
) reads allow_sub_emotes = True, and then reload this script if HexChat is already open.

Please be aware that this feature is not properly implemented yet, so right now, this will add over 13,000 emotes to the default list and will therefore probably cause some unwanted formatting. To disable subscriber emotes, set allow_sub_emotes to False (this is case sensitive!).

This script will retrieve information such as stream status, current game, and broadcast title when you join a TwitchTV IRC channel. It will update the channel topic with this information in addition to printing it locally. It will also update this information every 10 minutes, so if a stream goes offline for example, the topic will eventually change to reflect this.

This script has only been tested with Python 3 as of typing this.

Log URLs to disk for specified channels and private messages. This is a pretty useless script because HexChat can already log URLs to disk, but this script places the logged URLs in a unique directory: configdir/logs/:network/:channel/urls.txt. You probably don't want to use this script, but if you do, you should modify watched_channels to suit your needs. The regex is courtesy of [Matthew O'Riordan] (http://blog.mattheworiordan.com/post/13174566389/url-regular-expression-for-links-with-or-without-the).

Installation:

Place "script.py" in your HexChat addons folder:

  • Windows:
    • %APPDATA%\HexChat\addons
  • Linux:
    • ~/.config/hexchat/addons

The HexChat Python plugin interface is required.

Notes:

All scripts are under the MIT license unless otherwise stated.

I highly recommend checking out Farow's readme. Both he and TingPing have really useful scripts. Also check out my starred repositories to find additional scripts that I might have not yet listed below.

Here are some links in addition to Farow's:

GitHub

Elsewhere

Other interesting HexChat stuff

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages