Compare commits
2 Commits
09993218c6
...
0f775e150d
Author | SHA1 | Date | |
---|---|---|---|
|
0f775e150d | ||
|
f60561d470 |
3
our.rb
3
our.rb
@ -78,7 +78,6 @@ class User
|
||||
def loop
|
||||
while line = s.gets
|
||||
msg = Message.new line
|
||||
puts "S: #{msg.raw}"
|
||||
@hooks.each{|h| h.call(msg)}
|
||||
end
|
||||
end
|
||||
@ -119,7 +118,7 @@ i.hook do |msg|
|
||||
cmd, args = content.split(' ', 2)
|
||||
cmd = "#{cmds_dir}/#{cmd}"
|
||||
args ||= ''
|
||||
next unless File.exists? cmd
|
||||
next unless File.exist? cmd
|
||||
if not File.executable? cmd
|
||||
i.privmsg target, "#{cmd} isn't executable. try chmod +x"
|
||||
next
|
||||
|
@ -12,4 +12,5 @@ OUR_CMDS_DIR=${OUR_CMDS_DIR:-/town/our}
|
||||
--tmpfs /tmp \
|
||||
--unshare-pid \
|
||||
--die-with-parent \
|
||||
--uid 0 --gid 0 \
|
||||
"$@"
|
||||
|
Loading…
x
Reference in New Issue
Block a user