vbot 0.4.0 → 0.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/vbot/bot_controller.rb +10 -0
- metadata +6 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 54e12f6daddfa7dad387e86e4695667cc902aa64df8d97974a97bc11ac71bdb8
|
4
|
+
data.tar.gz: 07f514b539ffd2544ec26bde0bc7b07106462327dac27baeb5725e7e4d169521
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ae5bdac6995ca35c748d4a57c432e2fc3384e40f273026b1e340683acf814ed9bfd6040dee8f15cf3ab804bc11944b14d0ad3ecd54db46350323c56d5941094d
|
7
|
+
data.tar.gz: 67a625f9f3705fbd3f578029cf74781a71fdf0a4f32869a8df615b565633a7a22689acf319138bfccbeba79512d66eab8124212e001cde0fd343bea3282255fd
|
data/lib/vbot/bot_controller.rb
CHANGED
@@ -35,6 +35,8 @@ module Vbot
|
|
35
35
|
attr_reader :port
|
36
36
|
# The nick for the bot.
|
37
37
|
attr_reader :nick
|
38
|
+
# The pass for the bot.
|
39
|
+
attr_reader :pass
|
38
40
|
# The name to identify to the server with.
|
39
41
|
attr_reader :ident
|
40
42
|
# The gecos for the bot.
|
@@ -48,6 +50,7 @@ module Vbot
|
|
48
50
|
@server = config['server']
|
49
51
|
@port = config['port']
|
50
52
|
@nick = config['nick']
|
53
|
+
@pass = config['pass']
|
51
54
|
@ident = config['ident']
|
52
55
|
@gecos = config['gecos']
|
53
56
|
@chan = config['chan']
|
@@ -60,6 +63,7 @@ module Vbot
|
|
60
63
|
@socket = TCPSocket.open @server, @port
|
61
64
|
send_message nick_to_server
|
62
65
|
send_message ident_with_server
|
66
|
+
send_message identify_with_nickserv
|
63
67
|
end
|
64
68
|
|
65
69
|
##
|
@@ -98,6 +102,12 @@ module Vbot
|
|
98
102
|
["NICK #{@nick}\r\n"]
|
99
103
|
end
|
100
104
|
|
105
|
+
##
|
106
|
+
# Identifies with server.
|
107
|
+
def identify_with_nickserv
|
108
|
+
["PRIVMSG NickServ :IDENTIFY #{@pass}\r\n"]
|
109
|
+
end
|
110
|
+
|
101
111
|
##
|
102
112
|
# Identifies with server.
|
103
113
|
def ident_with_server
|
metadata
CHANGED
@@ -1,20 +1,20 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vbot
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Richard Davis
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-11-17 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: 'vbot is an IRC bot library that aims to be make building and extending
|
14
14
|
IRC bots more efficient.
|
15
15
|
|
16
|
-
'
|
17
|
-
email:
|
16
|
+
'
|
17
|
+
email: dick@rvdavis.me
|
18
18
|
executables: []
|
19
19
|
extensions: []
|
20
20
|
extra_rdoc_files: []
|
@@ -23,7 +23,7 @@ files:
|
|
23
23
|
- lib/vbot/base.rb
|
24
24
|
- lib/vbot/bot_controller.rb
|
25
25
|
- test/test_bot_controller.rb
|
26
|
-
homepage: http://
|
26
|
+
homepage: http://gitlab.com/d3d1rty/vbot
|
27
27
|
licenses:
|
28
28
|
- GPL-3.0
|
29
29
|
metadata: {}
|
@@ -42,8 +42,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
42
42
|
- !ruby/object:Gem::Version
|
43
43
|
version: '0'
|
44
44
|
requirements: []
|
45
|
-
|
46
|
-
rubygems_version: 2.7.6
|
45
|
+
rubygems_version: 3.0.3
|
47
46
|
signing_key:
|
48
47
|
specification_version: 4
|
49
48
|
summary: Ruby library for building IRC bots
|