Archived
1

Update dependencies

This commit is contained in:
2019-02-12 03:08:22 +04:00
parent ec46e63642
commit 85c7109a85
21 changed files with 25 additions and 13 deletions

View File

@@ -0,0 +1,10 @@
// Fantasy World Zookeeper Bot
// Copyright (c) 2018 Vladimir "fat0troll" Hodakov
package config
// Announces is a struct which handles announces configuration
type Announces struct {
ChannelID int64 `yaml:"channel_id"`
EnableLocal bool `yaml:"enable_local"`
}

12
internal/config/proxy.go Normal file
View File

@@ -0,0 +1,12 @@
// Fantasy World Zookeeper Bot
// Copyright (c) 2018 Vladimir "fat0troll" Hodakov
package config
// Proxy handles settings for Telegram SOCKS5 proxy
type Proxy struct {
Enabled bool `yaml:"enabled"`
Address string `yaml:"address,omitempty"`
Username string `yaml:"username,omitempty"`
Password string `yaml:"password,omitempty"`
}

11
internal/config/struct.go Normal file
View File

@@ -0,0 +1,11 @@
// Fantasy World Zookeeper Bot
// Copyright (c) 2018 Vladimir "fat0troll" Hodakov
package config
// Struct is a main configuration structure that holds all other
// structs within.
type Struct struct {
Telegram Telegram `yaml:"telegram"`
Announces Announces `yaml:"announces"`
}

View File

@@ -0,0 +1,11 @@
// Fantasy World Zookeeper Bot
// Copyright (c) 2018 Vladimir "fat0troll" Hodakov
package config
// Telegram represents bot's Telegram configuration
type Telegram struct {
Token string `yaml:"token"`
Webhook Webhook `yaml:"webhook"`
Proxy Proxy `yaml:"proxy"`
}

View File

@@ -0,0 +1,11 @@
// Fantasy World Zookeeper Bot
// Copyright (c) 2018 Vladimir "fat0troll" Hodakov
package config
// Webhook handles settings for Telegram webhook
type Webhook struct {
Enabled bool `yaml:"enabled"`
Domain string `yaml:"domain,omitempty"`
Listen string `yaml:"listen,omitempty"`
}