mirror of
https://github.com/IgorTimofeev/MineOS.git
synced 2026-01-06 19:22:40 +01:00
aefaef
This commit is contained in:
parent
ddc8ba107c
commit
a2eb2dbe27
@ -750,20 +750,20 @@
|
|||||||
["version"]=1.0,
|
["version"]=1.0,
|
||||||
},
|
},
|
||||||
----------------------------------------------------- Приложения с ресурсами --------------------------------------------------------------------------
|
----------------------------------------------------- Приложения с ресурсами --------------------------------------------------------------------------
|
||||||
{
|
-- {
|
||||||
["name"]="MineOS/Applications/VK",
|
-- ["name"]="MineOS/Applications/VK",
|
||||||
["url"]="IgorTimofeev/OpenComputers/master/Applications/VK/VK.lua",
|
-- ["url"]="IgorTimofeev/OpenComputers/master/Applications/VK/VK.lua",
|
||||||
["type"]="Application",
|
-- ["type"]="Application",
|
||||||
["icon"]="IgorTimofeev/OpenComputers/master/Applications/VK/Icon.pic",
|
-- ["icon"]="IgorTimofeev/OpenComputers/master/Applications/VK/Icon.pic",
|
||||||
["createShortcut"]="dock",
|
-- ["createShortcut"]="dock",
|
||||||
["version"]=1.0,
|
-- ["version"]=1.0,
|
||||||
["resources"]={
|
-- ["resources"]={
|
||||||
{
|
-- {
|
||||||
["name"]="VKLogo.pic",
|
-- ["name"]="VKLogo.pic",
|
||||||
["url"]="IgorTimofeev/OpenComputers/master/Applications/VK/VKLogo.pic",
|
-- ["url"]="IgorTimofeev/OpenComputers/master/Applications/VK/VKLogo.pic",
|
||||||
},
|
-- },
|
||||||
},
|
-- },
|
||||||
},
|
-- },
|
||||||
{
|
{
|
||||||
["name"]="MineOS/Applications/FlappyBird",
|
["name"]="MineOS/Applications/FlappyBird",
|
||||||
["url"]="IgorTimofeev/OpenComputers/master/Applications/FlappyBird/FlappyBird.lua",
|
["url"]="IgorTimofeev/OpenComputers/master/Applications/FlappyBird/FlappyBird.lua",
|
||||||
|
|||||||
46
Applications/VK/untitled.lua
Normal file
46
Applications/VK/untitled.lua
Normal file
@ -0,0 +1,46 @@
|
|||||||
|
|
||||||
|
local internet = require("component").internet
|
||||||
|
local url = "https://oauth.vk.com/token?grant_type=password&client_id=3697615&client_secret=AlVXZFMUqyrnABp8ncuU&username=Igor_Timofeev@me.com&password=3222288222238901371&v=5.50"
|
||||||
|
|
||||||
|
|
||||||
|
local response, errorMessage = internet.request(url)
|
||||||
|
|
||||||
|
if response then
|
||||||
|
local data = ""
|
||||||
|
local readedData
|
||||||
|
|
||||||
|
for key, val in pairs(response) do
|
||||||
|
print(key, val)
|
||||||
|
end
|
||||||
|
|
||||||
|
while true do
|
||||||
|
local readedData, readedReason = response.read()
|
||||||
|
if not readedData then
|
||||||
|
if readedReason then
|
||||||
|
ecs.error("Ашибачка при чтении: " .. readedReason)
|
||||||
|
break
|
||||||
|
else
|
||||||
|
break
|
||||||
|
end
|
||||||
|
else
|
||||||
|
data = data .. readedData
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
ecs.error("Ответ сервера: " .. tostring(data))
|
||||||
|
else
|
||||||
|
ecs.error("Ашибачка: " .. tostring(errorMessage))
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Loading…
x
Reference in New Issue
Block a user