-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathimporter.lua
More file actions
14 lines (14 loc) · 775 Bytes
/
importer.lua
File metadata and controls
14 lines (14 loc) · 775 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
print("Import your old tabchi without reentering the new SUDO id!")
print('Version 4 Of Tabchi')
redis = (loadfile "redis.lua")()
io.write("Enter Tabchi ID : ")
local last = io.read()
local sudo=redis:get("tabchi:"..last..":fullsudo")
io.write("\nEnter Full Sudo ID : "..sudo)
local text,ok = io.open("base.lua",'r'):read('*a'):gsub("TABCHI%-ID",last)
io.open("tabchi-"..last..".lua",'w'):write(text):close()
io.open("tabchi-"..last..".sh",'w'):write("while true; do\n./telegram-cli-1222 -p tabchi-"..last.." -s tabchi-"..last..".lua\ndone"):close()
io.popen("chmod 777 tabchi-"..last..".sh")
redis:set('tabchi:'..last..':fullsudo',sudo)
print("Done!\nNew Tabchi Created...\nID : "..last.."\nFull Sudo : "..sudo.."\nRun : ./tabchi-"..last..".sh")
print('Version 4 Of Tabchi')