2021-02-08T00:30:05 #kisslinux I mean, it's 30 lines of bash. That it works at all is awesome! 2021-02-08T03:24:24 #kisslinux you could always run `nc irc.freenode.net 6667` and pass server commands directly. no need for ircc but that just becomes annoying… no one wants to type PRIVMSG, USER, NICK and PING/PONG. 2021-02-08T03:24:53 #kisslinux i was really surprised though by the lack of examples on how to do this in POSIX shell (lots of bots examples, but no clients). In Bash, you can achieve the same functionality as ircc in fewer lines, but then you lose portability. 2021-02-08T05:52:15 #kisslinux is it even possible ? one would need to attach netcat to a bidirectional fd afaict 2021-02-08T12:27:16 #kisslinux sh4rm4^bnc: are you referring to using netcat alone? there no need to attach to a fd to handle the io stream… it does so inherently. 2021-02-08T12:53:13 #kisslinux prepending messages with "PRIVMSG #channel" is not that much of a big deal (can always paste it), responding to pings is the real problem when using `nc` alone 2021-02-08T13:31:28 #kisslinux aarng: Why not using shell aliases? 2021-02-08T13:32:31 #kisslinux tracer: you are not in a shell, it's netcat reading from stdin 2021-02-08T13:33:44 #kisslinux but that's why I like ii-style input from a fifo 2021-02-08T13:34:35 #kisslinux Hmm. how about a thin wrapper between hell and nc? 2021-02-08T13:34:45 #kisslinux s/hell/shell/g 2021-02-08T13:34:46 #kisslinux Hmm. how about a thin wrapper between shell and nc? 2021-02-08T13:35:03 #kisslinux isn't that what mcpcpc[m]'s script is? :) 2021-02-08T13:35:21 #kisslinux you could also use rlwrap I suppose 2021-02-08T13:35:47 #kisslinux I didn't check it out, sorry. 2021-02-08T13:36:06 #kisslinux no worries 2021-02-08T13:36:10 #kisslinux https://github.com/mcpcpc/ircc/blob/master/ircc 2021-02-08T13:36:40 #kisslinux For the time being I use Lime Chat. I'm not so pure about the smallest possible solution, just one that fits my needs. 2021-02-08T13:36:59 #kisslinux yeah, not a fan of smallest possible either 2021-02-08T13:37:03 #kisslinux raw irc is an unreadable mess 2021-02-08T13:38:13 #kisslinux Ah, yes, thats what I mean by a wrapper, can be easily extended. But, as there are so many IRC clients it's more just for fun or prrof of concept I guess. 2021-02-08T13:40:25 #kisslinux yeah, making the output prettier isn't too hard 2021-02-08T16:56:44 #kisslinux ircc you say 2021-02-08T17:09:15 #kisslinux ^^. i originally originally named it “shitirc”. also, pretty sure ircc is taken already. idk. not feeling very creative at the moment. or that it’s worth giving this wrapper script a name. lol. 2021-02-08T17:09:33 #kisslinux will probably just put it into a blog post 2021-02-08T17:22:06 #kisslinux mcpcpc[m]: You could host the source here: https://shithub.us/ 2021-02-08T17:28:35 #kisslinux lol. i thought about it actually. i dont think they are hosting any non-plan9 projects yet… 2021-02-08T17:39:22 #kisslinux mcpcpc[m]: https://termbin.com/ed55 2021-02-08T17:39:26 #kisslinux my take of your script 2021-02-08T17:40:34 #kisslinux doesn't need tail and all the pipes. This is basically runs just the script and a subshell (the loop reading user commands) 2021-02-08T17:40:46 #kisslinux -is 2021-02-08T17:44:59 #kisslinux aarng: ah. that looks much nicer. i hated the temp file, pipes and tail. 2021-02-08T17:46:37 #kisslinux nc -e is pretty cool, because it just sets up the socket/fds and execs the script 2021-02-08T17:46:51 #kisslinux check your processes when the script is running, not even a nc there :) 2021-02-08T17:50:18 #kisslinux ahh nice. i think i need to practice with shell scripting a bit more. i’ve spent too much time in C lately. 2021-02-08T17:53:05 #kisslinux heh, the original script was good though considering you didn't know about netcats -e flag 2021-02-08T18:00:07 #kisslinux meh. your rewrite was pretty enlightening. lots of concepts i know in C but didn’t know how to implement in shell. so i appreciate you taking the time to do it. :) 2021-02-08T18:02:59 #kisslinux you are welcome 2021-02-08T18:07:48 #kisslinux hm.. the -e argument seems to be lacking in some implementations (i.e. dash). still nifty though. 2021-02-08T18:11:40 #kisslinux I think all netcat implementations should have it 2021-02-08T18:13:53 #kisslinux nope, OpenBSD's -e is something different 2021-02-08T18:13:55 #kisslinux doh gemini://gemini.ctrl-c.club/~phoebos/logs/freenode-kisslinux-2021-02-08.txt

-- Leo's gemini proxy

-- Connecting to gemini.ctrl-c.club:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/plain; charset=utf-8

-- Response ended

-- Page fetched on Sun Jun 2 11:17:49 2024