updated ezconf
This commit is contained in:
@@ -9,12 +9,13 @@ import (
|
||||
)
|
||||
|
||||
type Config struct {
|
||||
ClientID string // ENV DISCORD_CLIENT_ID: Discord application client ID (required)
|
||||
ClientSecret string // ENV DISCORD_CLIENT_SECRET: Discord application client secret (required)
|
||||
OAuthScopes string // Authorisation scopes for OAuth
|
||||
RedirectPath string // ENV DISCORD_REDIRECT_PATH: Path for the OAuth redirect handler (required)
|
||||
BotToken string // ENV DISCORD_BOT_TOKEN: Token for the discord bot (required)
|
||||
GuildID string // ENV DISCORD_GUILD_ID: ID for the discord server the bot should connect to (required)
|
||||
ClientID string `ezconf:"DISCORD_CLIENT_ID,required,description:Discord application client ID"`
|
||||
ClientSecret string `ezconf:"DISCORD_CLIENT_SECRET,required,description:Discord application client secret"`
|
||||
RedirectPath string `ezconf:"DISCORD_REDIRECT_PATH,required,description:Path for the OAuth redirect handler"`
|
||||
BotToken string `ezconf:"DISCORD_BOT_TOKEN,required,description:Token for the discord bot"`
|
||||
GuildID string `ezconf:"DISCORD_GUILD_ID,required,description:ID for the discord server the bot should connect to"`
|
||||
|
||||
OAuthScopes string // Authorisation scopes for OAuth
|
||||
}
|
||||
|
||||
func ConfigFromEnv() (any, error) {
|
||||
|
||||
Reference in New Issue
Block a user