Skip to content
Snippets Groups Projects
Commit f71541de authored by Kasalehlia's avatar Kasalehlia
Browse files

redirected irc to kasas bouncer

parent e2ce2c78
No related branches found
No related tags found
No related merge requests found
...@@ -2,15 +2,22 @@ var irc = require('irc'); ...@@ -2,15 +2,22 @@ var irc = require('irc');
var CHANNEL = '#stratum0'; var CHANNEL = '#stratum0';
var PW = 'Fagee9ie'
module.exports = function (io) { module.exports = function (io) {
var client = new irc.Client('chat.freenode.net', 'infodisplay', { var client = new irc.Client('bouncer.ksal.de', 'infodisplay', {
channels: [CHANNEL] channels: [CHANNEL],
port: 28921,
secure: true,
selfSigned: true,
userName: 'infodisplay/Freenode',
password: PW
}); });
var content = []; var content = [];
client.addListener('message', function (from, to, message) { client.addListener('message', function (from, to, message) {
if (to != CHANNEL) {return;} if (to != CHANNEL || from === undefined) {return;}
message = message.replace(/</g,'&lt;').replace(/>/g,'&gt;'); message = message.replace(/</g,'&lt;').replace(/>/g,'&gt;');
content.push('<p>&nbsp;<span>'+from+'</span> '+message+'</p>'); content.push('<p><span>'+from+'</span> '+message+'</p>');
if (content.length > 25) { if (content.length > 25) {
content.shift(); content.shift();
} }
......
...@@ -17,6 +17,7 @@ body > div { ...@@ -17,6 +17,7 @@ body > div {
#irc p { #irc p {
margin: 0px; margin: 0px;
line-height: 120%; line-height: 120%;
padding-left: 1em;
} }
h2 { h2 {
margin: 0px; margin: 0px;
...@@ -33,6 +34,7 @@ h3 { ...@@ -33,6 +34,7 @@ h3 {
flex-direction: column; flex-direction: column;
height: calc(100% - 46px); height: calc(100% - 46px);
font-family: monospace; font-family: monospace;
overflow: hidden;
} }
#irc p span { #irc p span {
color: #268bd2; color: #268bd2;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment