net-irc 0.0.4 → 0.0.5
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.
- data/ChangeLog +16 -0
- data/Rakefile +1 -1
- data/examples/nig.rb +4 -0
- data/examples/tig.rb +159 -72
- data/examples/wig.rb +638 -32
- data/lib/net/irc.rb +1 -1
- data/lib/net/irc/client.rb +13 -129
- data/lib/net/irc/client/channel_manager.rb +144 -0
- data/lib/net/irc/constants.rb +1 -1
- data/lib/net/irc/message.rb +3 -1
- data/lib/net/irc/message/modeparser.rb +66 -25
- data/lib/net/irc/message/serverconfig.rb +30 -0
- data/spec/channel_manager_spec.rb +176 -0
- data/spec/modeparser_spec.rb +141 -19
- data/spec/net-irc_spec.rb +9 -69
- metadata +8 -6
- data/lib/net/irc/message/modeparser/hyperion.rb +0 -88
- data/lib/net/irc/message/modeparser/rfc1459.rb +0 -21
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: net-irc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- cho45
|
@@ -9,11 +9,11 @@ autorequire: ""
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2008-06
|
12
|
+
date: 2008-07-06 00:00:00 +09:00
|
13
13
|
default_executable:
|
14
14
|
dependencies: []
|
15
15
|
|
16
|
-
description:
|
16
|
+
description: library for implementing IRC server and client
|
17
17
|
email: cho45@lowreal.net
|
18
18
|
executables: []
|
19
19
|
|
@@ -29,18 +29,20 @@ files:
|
|
29
29
|
- spec/modeparser_spec.rb
|
30
30
|
- spec/net-irc_spec.rb
|
31
31
|
- spec/spec.opts
|
32
|
+
- spec/channel_manager_spec.rb
|
32
33
|
- lib/net
|
33
34
|
- lib/net/irc.rb
|
34
35
|
- lib/net/irc
|
36
|
+
- lib/net/irc/client
|
37
|
+
- lib/net/irc/client/channel_manager.rb
|
35
38
|
- lib/net/irc/constants.rb
|
36
39
|
- lib/net/irc/pattern.rb
|
37
40
|
- lib/net/irc/client.rb
|
38
41
|
- lib/net/irc/server.rb
|
39
42
|
- lib/net/irc/message.rb
|
40
43
|
- lib/net/irc/message
|
44
|
+
- lib/net/irc/message/serverconfig.rb
|
41
45
|
- lib/net/irc/message/modeparser
|
42
|
-
- lib/net/irc/message/modeparser/rfc1459.rb
|
43
|
-
- lib/net/irc/message/modeparser/hyperion.rb
|
44
46
|
- lib/net/irc/message/modeparser.rb
|
45
47
|
- examples/hatena-star-stream.rb
|
46
48
|
- examples/sig.rb
|
@@ -87,6 +89,6 @@ rubyforge_project: lowreal
|
|
87
89
|
rubygems_version: 1.2.0
|
88
90
|
signing_key:
|
89
91
|
specification_version: 2
|
90
|
-
summary:
|
92
|
+
summary: library for implementing IRC server and client
|
91
93
|
test_files: []
|
92
94
|
|
@@ -1,88 +0,0 @@
|
|
1
|
-
module Net::IRC::Message::ModeParser::Hyperion
|
2
|
-
Channel = Net::IRC::Message::ModeParser.new(%w|o l b v k q e|, {
|
3
|
-
:o => "channel ban",
|
4
|
-
:c => "color filter",
|
5
|
-
:d => "realname ban",
|
6
|
-
:e => "ban exemption",
|
7
|
-
:f => "forward on uninvited",
|
8
|
-
:g => "allow anybody to invite",
|
9
|
-
:i => "invite-only",
|
10
|
-
:I => "invite-only exemption",
|
11
|
-
:j => "jupe channel",
|
12
|
-
:J => "join throttling",
|
13
|
-
:k => "channel password",
|
14
|
-
:l => "join limit",
|
15
|
-
:L => "large ban/exempt /invex lists",
|
16
|
-
:m => "moderated",
|
17
|
-
:n => "prevent external send",
|
18
|
-
:p => "deprecated",
|
19
|
-
:P => "permanent channel",
|
20
|
-
:q => "quiet user",
|
21
|
-
:Q => "block forwarded users",
|
22
|
-
:r => "block unidentified",
|
23
|
-
:R => "quiet unidentified",
|
24
|
-
:s => "secret channel",
|
25
|
-
:t => "only ops can change topic",
|
26
|
-
:z => "reduced moderation",
|
27
|
-
})
|
28
|
-
User = Net::IRC::Message::ModeParser.new(%w||, {
|
29
|
-
:a => "user auspex",
|
30
|
-
:A => "server auspex",
|
31
|
-
:b => "see bots",
|
32
|
-
:B => "edit other people",
|
33
|
-
:c => "see client connections",
|
34
|
-
:C => "block ctcp",
|
35
|
-
:d => "debug",
|
36
|
-
:D => "die command",
|
37
|
-
:e => "identified",
|
38
|
-
:E => "reject messages from unidentified users",
|
39
|
-
:f => "full warning",
|
40
|
-
:F => "immune to flood protection",
|
41
|
-
:G => "global kill",
|
42
|
-
:h => "high priority",
|
43
|
-
:H => "rehash",
|
44
|
-
:i => "invisible",
|
45
|
-
:I => "refuse invite",
|
46
|
-
:j => "autodline",
|
47
|
-
:k => "server kill notices",
|
48
|
-
:K => "local kill",
|
49
|
-
:l => "channel creation notices",
|
50
|
-
:m => "immune",
|
51
|
-
:M => "mass notices",
|
52
|
-
:n => "nick change notices",
|
53
|
-
:N => "use any nick",
|
54
|
-
:o => "operator",
|
55
|
-
:p => "god mode",
|
56
|
-
:P => "setname and setident",
|
57
|
-
:Q => "disable forwarding",
|
58
|
-
:r => "notices on name rejections",
|
59
|
-
:R => "server routing",
|
60
|
-
:s => "server notices",
|
61
|
-
:S => "run commands remotely",
|
62
|
-
:T => "appear in STATS p",
|
63
|
-
:u => "join more channels",
|
64
|
-
:U => "unkline",
|
65
|
-
:v => "view privileges",
|
66
|
-
:V => "view routing",
|
67
|
-
:w => "receive wallops",
|
68
|
-
:W => "send wallops",
|
69
|
-
:x => "see servers joining",
|
70
|
-
:X => "experimental features",
|
71
|
-
:y => "spy",
|
72
|
-
:Y => "misc server connect notices",
|
73
|
-
:z => "receive operwall",
|
74
|
-
:Z => "send operwall",
|
75
|
-
:0 => "see opers",
|
76
|
-
:1 => "see connection settings",
|
77
|
-
:2 => "see network bans",
|
78
|
-
:3 => "see nick bans",
|
79
|
-
:4 => "see STATS T",
|
80
|
-
:5 => "see STATS ?",
|
81
|
-
:6 => "send/receive regardless of +E/noidprivmsg",
|
82
|
-
:9 => "use testline",
|
83
|
-
:* => "grant umodes",
|
84
|
-
})
|
85
|
-
end
|
86
|
-
|
87
|
-
|
88
|
-
|
@@ -1,21 +0,0 @@
|
|
1
|
-
module Net::IRC::Message::ModeParser::RFC1459
|
2
|
-
Channel = Net::IRC::Message::ModeParser.new(%w|o l b v k|, {
|
3
|
-
:o => "give/take channel operator privileges",
|
4
|
-
:p => "private channel flag",
|
5
|
-
:s => "select channel flag",
|
6
|
-
:i => "invite-only channel flag",
|
7
|
-
:t => "topic settable by channel operator only flag",
|
8
|
-
:n => "no messages to channel from clients on the outside",
|
9
|
-
:m => "moderated channel",
|
10
|
-
:l => "set the user limit to channel",
|
11
|
-
:b => "set a ban mask to keep users out",
|
12
|
-
:v => "give/take the ability to speak on a moderated channel",
|
13
|
-
:k => "set a channel key (password)",
|
14
|
-
})
|
15
|
-
User = Net::IRC::Message::ModeParser.new(%w||, {
|
16
|
-
:i => "marks a users as invisible",
|
17
|
-
:s => "marks a user for receipt of server notices",
|
18
|
-
:w => "user receives wallops",
|
19
|
-
:o => "operator flag",
|
20
|
-
})
|
21
|
-
end
|