Einige Fixes

This commit is contained in:
Akamaru 2016-03-27 16:03:31 +02:00
parent a249555a5d
commit fda6651444
7 changed files with 18 additions and 14 deletions

2
.gitignore vendored
View File

@ -17,3 +17,5 @@ plugins/plex_test.lua
plugins/gravatar.lua
pictures/3uhrmorgens.jpg
plugins/figuya.lua
plugins/plex_info.lua
plugins/plex_last.lua

View File

@ -560,6 +560,7 @@ function unescape(str)
str = string.gsub(str, "…", "")
str = string.gsub(str, "‹", "")
str = string.gsub(str, "€", "")
str = string.gsub(str, "♪", "")
-- Ä Ö Ü
str = string.gsub(str, "ä", "ä")

0
launch.sh Executable file → Normal file
View File

View File

@ -48,7 +48,7 @@ local data = json:decode(table.concat(response_body))._children[1]
end
if data.grandparentTitle then
from = ' (aus '..data.grandparentTitle..' ['..season..episode..']'..') '
from = ' (aus '..data.grandparentTitle..' ['..string.gsub(season..episode, 'S0E', 'SP')..']'..') '
else
from = ''
end
@ -98,7 +98,7 @@ local data = json:decode(table.concat(response_body))._children[1]
end
if data.summary then
desc = '\n\n'..string.gsub(data.summary, 'EditBackgroundNo(.*)', '')
desc = '\n\n'..string.gsub(unescape(data.summary), 'EditBackgroundNo(.*)', '')
else
desc = ''
end

View File

@ -8,12 +8,13 @@ end
function run(msg, matches)
local pics = {
-- add more below!
["test"] = "../USB/test/",
["anime"] = "../USB/sfw/anime/",
["mlp"] = "../USB/sfw/mlp/",
["faktillon"] = "../USB/sfw/faktillon/",
["faktastisch"] = "../USB/sfw/faktastisch/",
["gamefakt"] = "../USB/sfw/gamefakt/"
["test"] = "../Bilder/Mikubot/sfw/test/",
["anime"] = "../Bilder/Mikubot/sfw/anime/",
["mlp"] = "../Bilder/Mikubot/sfw/mlp/",
["faktillon"] = "../Bilder/Mikubot/sfw/faktillon/",
["faktastisch"] = "../Bilder/Mikubot/sfw/faktastisch/",
["gamefakt"] = "../Bilder/Mikubot/sfw/gamefakt/",
["faktglaublich"] = "../Bilder/Mikubot/sfw/faktglaublich/"
}
local receiver = get_receiver(msg)
@ -30,13 +31,13 @@ function run(msg, matches)
return "Fehler: " .. img
end
else
return '"'..imgtype..'" gibt es nicht.\nEs gibt:\nanime\nmlp\nfaktillon\nfaktastisch\ngamefakt'
return '"'..imgtype..'" gibt es nicht.\nEs gibt:\nanime\nmlp\nfaktillon\nfaktastisch\ngamefakt\nfaktglaublich'
end
end
return {
description = "Sendet ein zufälliges Bild",
usage = {"/rpic [Thema]","Themen:","anime","mlp","faktillon","faktastisch","gamefakt"},
usage = {"/rpic [Thema]","Themen:","anime","mlp","faktillon","faktastisch","gamefakt","faktglaublich"},
patterns = {"^/rpic (.*)$"},
run = run
}

View File

@ -8,8 +8,8 @@ end
function run(msg, matches)
local pics = {
-- add more below!
["/nsfw"] = "/home/pi/USB/nsfw/",
["/nsfw gif"] = "/home/pi/USB/nsfw/gifs/"
["/nsfw"] = "../Pictures/Mikubot/nsfw/",
["/nsfw gif"] = "../Pictures/Mikubot/nsfw/gifs/"
}
local receiver = get_receiver(msg)

View File

@ -71,7 +71,7 @@ function run(msg, matches)
return {
description = "Postet den URL-Titel",
usage = {""},
patterns = {"^(https?://[%w-_%.%?%.:,/%+=&#!]+)$"},
patterns = {"^(https?://[%w-_%.%?%.:,/%+=&#!%%]+)$"},
run = run
}
end