new plugins
change_pic.lua: Change the group picture rename:lua Rename group name
This commit is contained in:
parent
c121bff69a
commit
76699da739
3
.gitignore
vendored
3
.gitignore
vendored
@ -45,4 +45,5 @@ plugins/dantest.lua
|
||||
plugins/flickr.lua
|
||||
plugins/flickr_search.lua
|
||||
plugins/google_books.lua
|
||||
plugins/safebrowsing.lua
|
||||
plugins/safebrowsing.lua
|
||||
plugins/random.lua
|
14
plugins/change_pic.lua
Normal file
14
plugins/change_pic.lua
Normal file
@ -0,0 +1,14 @@
|
||||
function run(msg, matches)
|
||||
local receiver = get_receiver(msg)
|
||||
local url = matches[1]
|
||||
local file = download_to_file(url)
|
||||
local cb_extra = {file_path=file}
|
||||
chat_set_photo(receiver, file, ok_cb, false)
|
||||
end
|
||||
|
||||
return {
|
||||
description = "",
|
||||
usage = {""},
|
||||
patterns = {"^/pic (.*)$"},
|
||||
run = run
|
||||
}
|
12
plugins/rename.lua
Normal file
12
plugins/rename.lua
Normal file
@ -0,0 +1,12 @@
|
||||
function run(msg, matches)
|
||||
local receiver = get_receiver(msg)
|
||||
local text = matches[1]
|
||||
rename_chat(receiver, text, ok_cb, false)
|
||||
end
|
||||
|
||||
return {
|
||||
description = "",
|
||||
usage = {""},
|
||||
patterns = {"^/rename (.*)$"},
|
||||
run = run
|
||||
}
|
Reference in New Issue
Block a user