Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/veonik/squircy2
Golang IRC bot, scriptable with javascript
https://github.com/veonik/squircy2
bot go golang irc-bot
Last synced: about 22 hours ago
JSON representation
Golang IRC bot, scriptable with javascript
- Host: GitHub
- URL: https://github.com/veonik/squircy2
- Owner: veonik
- License: mit
- Created: 2014-10-21T03:29:49.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2019-06-03T05:17:45.000Z (over 5 years ago)
- Last Synced: 2024-06-19T01:57:16.311Z (5 months ago)
- Topics: bot, go, golang, irc-bot
- Language: Go
- Homepage: https://squircy.com
- Size: 431 KB
- Stars: 18
- Watchers: 2
- Forks: 5
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
squIRCy2
========##### the scriptable IRC bot
squIRCy2 is an IRC bot written in Go and is scriptable using an embedded JavaScript runtime.
It features a robust CLI with REPL and auto-completion, a web management interface, an embedded document store, and event based in-program communication.
Customize the bot's functionality with JavaScript. Bind event handlers to handle events that occur in the application. Events come from IRC, the CLI, or even the web.
Installation
------------Install squIRCy2 with `go get`.
```bash
go get -u "github.com/veonik/squircy2/..."
```After squIRCy2 is installed, you can run it immediately with `squircy2`. On first run, a default configuration will be initialized in `~/.squircy2`.
```
squircy2
```> For information on modifying and customizing squIRcy2, see [Contributing](docs/customizing.md).
Usage
-----squIRCy2 command-line usage.
```
squIRcy2 version dev (go1.8)
Usage: squircy2 [-no-interactive] [-root-path ] [-version]-no-interactive
Run without user interaction.
-root-path string
Specify a custom root path. (default "~/.squircy2")
-version
Display the version and exit.
```Customize where squIRCy2 stores data by specifying a custom `-root-path`. Specifying `-no-interactive` will disable the CLI.
### Command line
The squIRCy2 command line starts in "Command Mode" which offers a few basic commands, including connecting/disconnecting from IRC, enabling/disabling the web server, and starting a REPL.
Enter "REPL Mode" by entering the `repl` command. This REPL features history navigable with the arrow keys, history search with CTRL+R, and auto-completion with TAB.Configuration
-------------Once the bot is up and running, you can access the web management interface via `localhost:3000`. From this interface you can write scripts and use a web-based REPL, as well as configure squIRCy2 to your liking.
### Configuration overview
From the Settings page, you can configure:
* **IRC**
* Configure the Network, Nickname and Username information for the bot. You can also enable TLS-- be sure to specify a TLS-capable port for the Network.
* Enable SASL authentication and enter your NickServ username and password. **Note these are stored plaintext in a blob format.**
* Owner Nick and Host can be used from within scripts to verify a user's ownership of the bot. See [the JavaScript reference](docs/js-api.md) for more information.
* **Script Management**
* If you prefer to work with an external editor, you can have squIRCy2 load scripts on the filesystem. Specify a path, enable the option, and restart squIRCy2.
* Import and Export scripts from the embedded data store.
* **Web Interface**
* Disable the web interface completely by disabling both HTTP and HTTPS.
* Configure HTTPS by specifying a certificate file and private key.
* Configure HTTP(S) Basic Authentication with a Username and Password. **Note these are stored plaintext in a blob format.**Scripting
---------squIRCy2 embeds a JavaScript interpreter, allowing you to write scripts to implement various bot behaviors.
### JavaScript API
A full introduction to the squIRCy2 JavaScript API can be found in [the JavaScript API reference](docs/js-api.md).
#### Example scripts
Check the [Example Scripts section](docs/examples.md) for ideas for squIRCy2 scripts.
### Webhooks
See the [dedicated section on Webhooks](docs/webhooks.md).