Highly-opinionated (ex-bullshit-free) MTPROTO proxy for Telegram. If you use v1.0 or upgrade broke you proxy, please read the chapter Version 2
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

1234567891011121314151617181920212223
  1. // mtg is just a command-line application that starts a proxy.
  2. //
  3. // Application logic is how to read a config and configure mtglib.Proxy.
  4. // So, probably you need to read the documentation for mtglib package
  5. // first.
  6. //
  7. // mtglib is a core of the application. The rest of the packages provide
  8. // some default implementations for the interfaces, defined in mtglib.
  9. package main
  10. import (
  11. "github.com/9seconds/mtg/v2/internal/cli"
  12. "github.com/alecthomas/kong"
  13. )
  14. func main() {
  15. cli := &cli.CLI{}
  16. ctx := kong.Parse(cli, kong.Vars{
  17. "version": getVersion(),
  18. })
  19. ctx.FatalIfErrorf(ctx.Run(cli, version))
  20. }