tg-api-lua/readme.org

31 lines
748 B
Org Mode
Raw Permalink Normal View History

2021-08-16 08:47:49 +00:00
* Telegram API
2022-08-10 09:50:56 +00:00
This is bindings of Telegram API written in Lua, part of [[https://gitdab.com/er2/comp-tg][my bot]].
2021-08-16 08:47:49 +00:00
* Installation
2022-08-10 09:50:56 +00:00
Yourpath is any directory inside your project.
Recommended to use *.gitmodules* file for that.
2021-08-16 08:47:49 +00:00
To include, add to gitmodules this:
#+begin_src
[submodule "tg-api"]
2022-08-10 09:50:56 +00:00
path = yourpath/api
2021-08-16 08:47:49 +00:00
url = https://gitdab.com/er2/tg-api-lua
#+end_src
Also you need to:
+ Install *LuaSec* for https requests.
+ Execute this code *before* include this API:
#+begin_src lua
package.path = 'yourpath/?.lua;yourpath/?/init.lua;' .. package.path
#+end_src
2022-08-10 09:50:56 +00:00
+ Copy to yourpath files *class.lua*, *event.lua*, *json.lua*
2021-08-16 08:47:49 +00:00
They can be taken from [[https://gitdab.com/er2/comp-tg/src/branch/main/etc][here]].