IRC bot which informs new joiners the channel has moved to a new server
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
Agastya 0c7d58ddd9 fixed typo 2 months ago
prisma findFirst instead of unique 2 months ago
.gitignore update gitignore + rm channels 2 months ago
LICENSE Initial commit 2 months ago
config.js add readme 2 months ago
index.js fixed typo 2 months ago
package.json Add start script and handle null. 2 months ago
readme.asc add readme 2 months ago
yarn.lock update gitignore + rm channels 2 months ago

readme.asc

                                    ____  _ _ _                    
_ __ ___ _ ___ _|___ \| (_) |__ ___ _ __ __ _
| '_ ` _ \| | | \ \ / / __) | | | '_ \ / _ \ '__/ _` |
| | | | | | |_| |\ V / / __/| | | |_) | __/ | | (_| |
|_| |_| |_|\__,_| \_/ |_____|_|_|_.__/ \___|_| \__,_|

---

IRC bot to inform new joiners the channel has been moved.

---

Edit the config.js file to configure the options.

* oldServerUrl: The URL of the old server, where the bot should join.
* botName: The IRC nick of the bot.
* ignoreNicks: The bot won't notify these users to join a new channel.
This is a hack to avoid the bot informing itself, ChanServ, and possibly the maintainers about the move, as that would be redundant.
* newServer: Contains the link to the new server.
* channels: contains the channels on the old server the bot monitors and performs this task.
* joinTreshholdSecs: When the user joins, the bot notifies them about the move.
If the user parts and rejoins within this treshhold time, don't inform them again.

---

The information about the user joining a channel is stored in SQLite db.

After cloning the repo, run either one of the following commands.

npm i -D
or
yarn

These will install the dependencies.

After that, initialise the database by running the following two commands.

prisma generate
prisma migrate dev --name=init

---

Run the following command to run the bot.

node start