Giter Club home page Giter Club logo

Comments (26)

ekmartin avatar ekmartin commented on August 12, 2024

Disable the what? I don't think I'm completely following you, could you try to explain a bit further?

from slack-irc.

flewid avatar flewid commented on August 12, 2024

Sure, sorry I wasn't clear.

So, I have the bot setup to connect to an irc channel, so, my nick of the bot on irc is say "botnick" and then my nickname on slack is "slacknick".

If a message comes into slack, it shows up fine, but, if I then reply through slack and it shows up on irc as;

< botnick > < slacknick > my message

whereas, it'd be nicer if i could set an option per channel to just have it be

< botnick > my message

from slack-irc.

ekmartin avatar ekmartin commented on August 12, 2024

I think I get what you mean, but I'm not sure if I see the point. The <slacknick> is there to make it clear for the people in your IRC channel that it's in fact slacknick that's talking. What's the use case for not letting people in your IRC channel know who they're talking to from your Slack channel?

from slack-irc.

flewid avatar flewid commented on August 12, 2024

Sure, I think I'm using it a bit differently than most, in that what I'm doing is connecting to IRC so I can keep in touch through the desktop and web app with my friends, however, I'm basically just using it as a "user" for myself on the channel, so it's annoying for other members of the channel to see < nickname > < slack nick > my message, and would be better if it simply ran as a regular user does, for my particular use case anyways.

from slack-irc.

ekmartin avatar ekmartin commented on August 12, 2024

So you're sort of using Slack as an IRC client?

from slack-irc.

flewid avatar flewid commented on August 12, 2024

yup, pretty much, just woudl be nice to have this option per channel for
when i'm using it this way, instead of a relay bot for a whole channel to
slack :)

On Fri, Mar 27, 2015 at 5:09 PM, Martin Ek [email protected] wrote:

So you're sort of using Slack as an IRC client?


Reply to this email directly or view it on GitHub
#19 (comment).

  ∴ *Matthew Gibson*

from slack-irc.

ekmartin avatar ekmartin commented on August 12, 2024

Hm, I'll think about it. I'm going on vacation tomorrow though, so probably won't happen for at least a week. You could of course just use slack's IRC gateway, but I guess that would be a bit opposite (since you want to use the Slack client for IRC and not an IRC client for Slack).

from slack-irc.

flewid avatar flewid commented on August 12, 2024

Not a problem :)

I can probably hack the source for now to do it across all channels instead
of just a few select ones. Have a ncie vacation!

On Fri, Mar 27, 2015 at 5:19 PM, Martin Ek [email protected] wrote:

Hm, I'll think about it. I'm going on vacation tomorrow though, so
probably won't happen for at least a week. You could of course just use slack's
IRC gateway
https://slack.zendesk.com/hc/en-us/articles/201727913-Connecting-to-Slack-over-IRC-and-XMPP,
but I guess that would be a bit opposite (since you want to use the Slack
client for IRC and not an IRC client for Slack).


Reply to this email directly or view it on GitHub
#19 (comment).

  ∴ *Matthew Gibson*

from slack-irc.

ekmartin avatar ekmartin commented on August 12, 2024

Thanks! This is what decides what gets printed to IRC, if you decide to change it: https://github.com/ekmartin/slack-irc/blob/master/lib%2Fbot.js#L130

from slack-irc.

flewid avatar flewid commented on August 12, 2024

Great thanks :)

from slack-irc.

garagatyi avatar garagatyi commented on August 12, 2024

What if:

  1. Add to conf of bot mapping of slack_username -> IRC credentials
  2. Bot makes signin for himself, and then login for every provided mapping
  3. If user from mapping write something in Slack, bot write it in IRC as separate IRC user
  4. If user not from mapping write something in Slack, bot write it as usual with username in brackets

Pros:

  1. Allows to show every user in slack channel as separate user in IRC channel, so channel will look more active. Current 1 bot per all slack users make channel empty.
  2. Allows usage bot as Slack to IRC proxy as issue initiator asks.

from slack-irc.

flewid avatar flewid commented on August 12, 2024

will this handle private messages as well? (so if someone on irc messages
me, it'll pop up as a DM and I can reply?

On Thu, Apr 9, 2015 at 1:09 PM, Alexander Garagatyi <
[email protected]> wrote:

What if:

  1. Add to conf of bot mapping of slack_username -> IRC credentials
  2. Bot makes signin for himself, and then login for every provided mapping
  3. If user from mapping write something in Slack, bot write it in IRC as
    separate IRC user
  4. If user not from mapping write something in Slack, bot write it as
    usual with username in brackets

Pros:

  1. Allows to show every user in slack channel as separate user in IRC
    channel, so channel will look more active. Current 1 bot per all slack
    users make channel empty.
  2. Allows usage bot as Slack to IRC proxy as issue initiator asks.


Reply to this email directly or view it on GitHub
#19 (comment).

  ∴ *Matthew Gibson*

from slack-irc.

garagatyi avatar garagatyi commented on August 12, 2024

It can be implemented too

from slack-irc.

flewid avatar flewid commented on August 12, 2024

okay that would be really cool, so it could be flagged as client, or relay
server so could make it join a private group when it's as a client, and
public channel when it's a relay, that sounds amazing :)

On Fri, Apr 10, 2015 at 2:49 AM, Alexander Garagatyi <
[email protected]> wrote:

It can be implemented too


Reply to this email directly or view it on GitHub
#19 (comment).

  ∴ *Matthew Gibson*

from slack-irc.

garagatyi avatar garagatyi commented on August 12, 2024

Yes, it's cool, but I'm not familiar with Node and javascript, so it's not so easy for me to implement it in free time.
Could @ekmartin or someone else do that?

from slack-irc.

ekmartin avatar ekmartin commented on August 12, 2024

What if:

  1. Add to conf of bot mapping of slack_username -> IRC credentials
  2. Bot makes signin for himself, and then login for every provided mapping
  3. If user from mapping write something in Slack, bot write it in IRC as separate IRC user
  4. If user not from mapping write something in Slack, bot write it as usual with username in brackets

I might be misunderstanding something here @garagatyi, but 2) would require you to run a separate IRC bot for each user mapping. Also, how could you login multiple users without putting all of their passwords in the config (which really isn't something anyone should want to do)?

Private messages could be forwarded to a channel, and replied to through some kind of command sent from Slack (!msg username hi in a Slack channel or similar), but I'm afraid it'd result in a quite hacky solution in the end. Even though I understand why you'd want to be able to use Slack as an IRC client @flewid I think the end product would be sort of working at best, and that you're better of just running a separate IRC client.

from slack-irc.

flewid avatar flewid commented on August 12, 2024

msg's would be nice, but not integral to me -- the current way i have it
working (just doesn't show username on relay) is fine enough for me -- i
found another solution that I can install on irssi that'll relay msg's via
xmpp to slack so I may just go that route and leave irssi screened on a
shell. but if we could have the ability to have 'silent' mode for the bot
or something (so it doesn't show usernames on relay to use it as a 'kind
of' client, that'd be cool).

On Sun, Apr 12, 2015 at 1:12 PM, Martin Ek [email protected] wrote:

What if:

  1. Add to conf of bot mapping of slack_username -> IRC credentials
  2. Bot makes signin for himself, and then login for every provided mapping
  3. If user from mapping write something in Slack, bot write it in IRC as
    separate IRC user
  4. If user not from mapping write something in Slack, bot write it as
    usual with username in brackets

I might be misunderstanding something here @garagatyi
https://github.com/garagatyi, but 2) would require you to run a
separate IRC bot for each user mapping. Also, how could you login multiple
users without putting all of their passwords in the config (which really
isn't something anyone should want to do)?

Private messages could be forwarded to a channel, and replied to
through some kind of command sent from Slack (!msg username hi in a Slack
channel or similar), but I'm afraid it'd result in a quite hacky solution
in the end. Even though I understand why you'd want to be able to use Slack
as an IRC client @flewid https://github.com/flewid I think the end
product would be sort of working at best, and that you're better of just
running a separate IRC client.


Reply to this email directly or view it on GitHub
#19 (comment).

  ∴ *Matthew Gibson*

from slack-irc.

garagatyi avatar garagatyi commented on August 12, 2024

@ekmartin Yes, you are right that multiple irc clients should be started, and passwords should be in the settings. It's big disadvantage. But I propose it as optional. And it will be huge improvement because now channel with bot looks abandoned.

As I understand @ekmartin you are not a big fan of such big changes. I understand you.

from slack-irc.

tcr avatar tcr commented on August 12, 2024

I have some of these ideas working in a fork, it's very hacky but it felt worth exploring. https://github.com/tcr/slack-irc

One bot is dedicated for forwarding messages. Each other bot is married to a particular IRC account. To "whitelist" users is to add their name to the bot list; non-whitelisted users have their messages deleted from the IRC chatroom and a PM sent to them saying to request whitelisting.

This optimizes for the use case of everyone in Slack can read messages, but only particular people may use it as their actual IRC chat client.

from slack-irc.

ekmartin avatar ekmartin commented on August 12, 2024

@tcr, is your usecase for whitelisting to let multiple users use Slack as a sort of pseudo IRC-client? Also, do you identify/authenticate the individual IRC users in any way? It's an interesting approach, albeit I agree that it's a bit hacky.

from slack-irc.

tcr avatar tcr commented on August 12, 2024

@ekmartin (Totally hacky.) My goal was to explore Slack as our primary collaboration tool, but allow us to do IRC support without our (whitelisted) teammates needing a separate client. Since only a finite group of people want this setup, it's easy to hard-code each user as a separately named bot.

Authentication is done simply by slack username matched against a bot's configuration. The configuration stores credentials for every IRC user, just like any bot's password.

from slack-irc.

Deph0 avatar Deph0 commented on August 12, 2024

I'd just like to point out the actual line is at bot.js#L170

I had to search for this place when i wanted to prevent self-pinging on irc, but on discord-irc.
I figured it out with the use of \u0081 (control character) or \u200b (zero width space)
Haven't decided which one ill continue to use, somebody using irssi told me they saw the controlchar, but not zerowidth, and other people saying the other way around (or seeing none of them).

I'll leave the code snippet incase somebody is interested:

      var usrnm = username.charAt(0) + '\u200b' + username.substring(1); // bake it inside the nickname
      text = '<' + usrnm + '> ' + text; 

from slack-irc.

siennathesane avatar siennathesane commented on August 12, 2024

Does line #167 contain the actual msg format to be delivered to IRC as a message payload?

I really want to utilise this, but I want to be able to impersonate myself as much as possible. Maybe @ekmartin can write a small README on how to customise the project for individuals, without actually changing the project for this use case?

from slack-irc.

ekmartin avatar ekmartin commented on August 12, 2024

@mynameismevin see #56. That would let you set ircUsernameFormat to an empty string, i.e. no username at all. I'm still of the opinion that there could be much better solutions if the aim was to use Slack as a personal IRC client though (like being able to private message people on IRC and similar), slightly relevant: reactiflux/discord-irc#12 (comment)

Implementing the two configuration options needed for #56 isn't much work though, so if it's something that could be useful I'll add it.

from slack-irc.

aeirola avatar aeirola commented on August 12, 2024

I've also been looking for a way to replace my IRC client with something based on Slack, due to the nicer mobile client. I created a project at aeirola/slack-irc-client which enables using Slack as a personal IRC client. I think something like this is what @ekmartin was referring to as better solution for handling private messages and such.

from slack-irc.

ekmartin avatar ekmartin commented on August 12, 2024

Superb, great work! I've added a section in the README, with a link to the project.

from slack-irc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.