nakiircbot 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 48ee5e5b5a294eb86f735eddd3f8fe9e556dc8b630e77f03cc7b3be118f01d69
4
- data.tar.gz: 2ee18ee0686a4a53a777f107846b538860d330b495c5294f1e0efd0612c1dbaa
3
+ metadata.gz: c2e6b769a530d14c8ec9a913a753d43d024abed583003e450c98fa8001bd9e65
4
+ data.tar.gz: 716cd2ebaaed6f05a3464d5834876e189f5cdfe99c91faf6426dada6b9a7c0fb
5
5
  SHA512:
6
- metadata.gz: cdf6b65b35360cb21889ef9969a2f166ad3e928a20ca128970b0b49734fd3a547a412f87280b112e675014a97bd906c7f7f6a0df3b9429ff6c0397f544400f5f
7
- data.tar.gz: fe10d2e4c2966e00242f9f17b6fae3342250da520074afb6e5871d0f2d02c5a2aa8030197765855899d264d2bfdfd42950960b62dfac3fab25a5884fca9d7561
6
+ metadata.gz: 25c03c973d93b85f7d722893fee1f806396bcaa1a56da028ce0b634f6e9f6b2f802234a4d85c6991a3905b18544f4f8ec0910ca72431c46e03d6b34578442c36
7
+ data.tar.gz: 31a6a42f98e43b8b11592abe5696305284c8413c2dc8acd212d7771bbf020b513ca9406a17f1a5db5e4659056ec81d177e36eb3a041b6af46ce895d3a35aa3d4
data/lib/nakiircbot.rb CHANGED
@@ -45,7 +45,7 @@ module NakiIRCBot
45
45
  next unless addr && msg
46
46
  addr = addr.codepoints.pack("U*")
47
47
  fail "I should not PRIVMSG myself" if addr == bot_name
48
- msg = msg.to_s.codepoints.pack("U*").chomp[/[^\x01].*/m].gsub("\x00", "[NUL]").gsub("\x0A", "[LF]").gsub("\x0D", "[CR]")
48
+ msg = msg.to_s.codepoints.pack("U*").chomp[/^(\x01*)(.*)/m,2].gsub("\x00", "[NUL]").gsub("\x0A", "[LF]").gsub("\x0D", "[CR]")
49
49
  privmsg = "PRIVMSG #{addr} :#{msg}"[0,513]
50
50
  privmsg[-4..-1] = "..." until privmsg.bytesize <= 475 # Libera in fact cuts last ~31 bytes
51
51
  prev_socket_time = prev_privmsg_time = Time.now
data/nakiircbot.gemspec CHANGED
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |spec|
2
2
  spec.name = "nakiircbot"
3
- spec.version = "0.1.0"
3
+ spec.version = "0.1.1"
4
4
  spec.summary = "IRC bot framework"
5
5
 
6
6
  spec.author = "Victor Maslov aka Nakilon"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nakiircbot
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Victor Maslov aka Nakilon
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-06-05 00:00:00.000000000 Z
11
+ date: 2021-06-10 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description:
14
14
  email: nakilon@gmail.com