Documentation ¶
Index ¶
- Variables
- func DoUpgrade(helper *up.Helper)
- type BackfillLimitPart
- type BridgeConfig
- func (bc *BridgeConfig) EnableMessageErrorNotices() bool
- func (bc *BridgeConfig) EnableMessageStatusEvents() bool
- func (bc BridgeConfig) FormatChannelName(params ChannelNameParams) string
- func (bc BridgeConfig) FormatDisplayname(user *discordgo.User, webhook, application bool) string
- func (bc BridgeConfig) FormatGuildName(params GuildNameParams) string
- func (bc BridgeConfig) FormatUsername(userID string) string
- func (bc BridgeConfig) GetCommandPrefix() string
- func (bc BridgeConfig) GetDoublePuppetConfig() bridgeconfig.DoublePuppetConfig
- func (bc BridgeConfig) GetEncryptionConfig() bridgeconfig.EncryptionConfig
- func (bc BridgeConfig) GetManagementRoomTexts() bridgeconfig.ManagementRoomTexts
- func (bc *BridgeConfig) GetResendBridgeInfo() bool
- func (bc *BridgeConfig) UnmarshalYAML(unmarshal func(interface{}) error) error
- func (bc *BridgeConfig) Validate() error
- type ChannelNameParams
- type Config
- type DisplaynameParams
- type GuildNameParams
- type MediaPatterns
- func (mp *MediaPatterns) Attachment(channelID, attachmentID, filename string) id.ContentURI
- func (mp *MediaPatterns) Avatar(userID, avatarID, ext string) id.ContentURI
- func (mp *MediaPatterns) Emoji(emojiID, ext string) id.ContentURI
- func (mp *MediaPatterns) Sticker(stickerID, ext string) id.ContentURI
- func (mp *MediaPatterns) UnmarshalYAML(unmarshal func(interface{}) error) error
Constants ¶
This section is empty.
Variables ¶
View Source
var SpacedBlocks = [][]string{
{"homeserver", "software"},
{"appservice"},
{"appservice", "hostname"},
{"appservice", "database"},
{"appservice", "id"},
{"appservice", "as_token"},
{"bridge"},
{"bridge", "command_prefix"},
{"bridge", "management_room_text"},
{"bridge", "encryption"},
{"bridge", "provisioning"},
{"bridge", "permissions"},
{"logging"},
}
Functions ¶
Types ¶
type BackfillLimitPart ¶ added in v0.3.0
type BridgeConfig ¶
type BridgeConfig struct { UsernameTemplate string `yaml:"username_template"` DisplaynameTemplate string `yaml:"displayname_template"` ChannelNameTemplate string `yaml:"channel_name_template"` GuildNameTemplate string `yaml:"guild_name_template"` PrivateChatPortalMeta string `yaml:"private_chat_portal_meta"` PrivateChannelCreateLimit int `yaml:"startup_private_channel_create_limit"` PortalMessageBuffer int `yaml:"portal_message_buffer"` DeliveryReceipts bool `yaml:"delivery_receipts"` MessageStatusEvents bool `yaml:"message_status_events"` MessageErrorNotices bool `yaml:"message_error_notices"` RestrictedRooms bool `yaml:"restricted_rooms"` AutojoinThreadOnOpen bool `yaml:"autojoin_thread_on_open"` EmbedFieldsAsTables bool `yaml:"embed_fields_as_tables"` MuteChannelsOnCreate bool `yaml:"mute_channels_on_create"` SyncDirectChatList bool `yaml:"sync_direct_chat_list"` ResendBridgeInfo bool `yaml:"resend_bridge_info"` CustomEmojiReactions bool `yaml:"custom_emoji_reactions"` DeletePortalOnChannelDelete bool `yaml:"delete_portal_on_channel_delete"` DeleteGuildOnLeave bool `yaml:"delete_guild_on_leave"` FederateRooms bool `yaml:"federate_rooms"` PrefixWebhookMessages bool `yaml:"prefix_webhook_messages"` EnableWebhookAvatars bool `yaml:"enable_webhook_avatars"` UseDiscordCDNUpload bool `yaml:"use_discord_cdn_upload"` CacheMedia string `yaml:"cache_media"` MediaPatterns MediaPatterns `yaml:"media_patterns"` AnimatedSticker struct { Target string `yaml:"target"` Args struct { Width int `yaml:"width"` Height int `yaml:"height"` FPS int `yaml:"fps"` } `yaml:"args"` } `yaml:"animated_sticker"` DoublePuppetConfig bridgeconfig.DoublePuppetConfig `yaml:",inline"` CommandPrefix string `yaml:"command_prefix"` ManagementRoomText bridgeconfig.ManagementRoomTexts `yaml:"management_room_text"` Backfill struct { Limits struct { Initial BackfillLimitPart `yaml:"initial"` Missed BackfillLimitPart `yaml:"missed"` } `yaml:"forward_limits"` MaxGuildMembers int `yaml:"max_guild_members"` } `yaml:"backfill"` Encryption bridgeconfig.EncryptionConfig `yaml:"encryption"` Provisioning struct { Prefix string `yaml:"prefix"` SharedSecret string `yaml:"shared_secret"` DebugEndpoints bool `yaml:"debug_endpoints"` } `yaml:"provisioning"` Permissions bridgeconfig.PermissionConfig `yaml:"permissions"` // contains filtered or unexported fields }
func (*BridgeConfig) EnableMessageErrorNotices ¶
func (bc *BridgeConfig) EnableMessageErrorNotices() bool
func (*BridgeConfig) EnableMessageStatusEvents ¶
func (bc *BridgeConfig) EnableMessageStatusEvents() bool
func (BridgeConfig) FormatChannelName ¶
func (bc BridgeConfig) FormatChannelName(params ChannelNameParams) string
func (BridgeConfig) FormatDisplayname ¶
func (bc BridgeConfig) FormatDisplayname(user *discordgo.User, webhook, application bool) string
func (BridgeConfig) FormatGuildName ¶
func (bc BridgeConfig) FormatGuildName(params GuildNameParams) string
func (BridgeConfig) FormatUsername ¶
func (bc BridgeConfig) FormatUsername(userID string) string
func (BridgeConfig) GetCommandPrefix ¶
func (bc BridgeConfig) GetCommandPrefix() string
func (BridgeConfig) GetDoublePuppetConfig ¶ added in v0.6.2
func (bc BridgeConfig) GetDoublePuppetConfig() bridgeconfig.DoublePuppetConfig
func (BridgeConfig) GetEncryptionConfig ¶
func (bc BridgeConfig) GetEncryptionConfig() bridgeconfig.EncryptionConfig
func (BridgeConfig) GetManagementRoomTexts ¶
func (bc BridgeConfig) GetManagementRoomTexts() bridgeconfig.ManagementRoomTexts
func (*BridgeConfig) GetResendBridgeInfo ¶
func (bc *BridgeConfig) GetResendBridgeInfo() bool
func (*BridgeConfig) UnmarshalYAML ¶
func (bc *BridgeConfig) UnmarshalYAML(unmarshal func(interface{}) error) error
func (*BridgeConfig) Validate ¶
func (bc *BridgeConfig) Validate() error
type ChannelNameParams ¶
type Config ¶
type Config struct { *bridgeconfig.BaseConfig `yaml:",inline"` Bridge BridgeConfig `yaml:"bridge"` }
type DisplaynameParams ¶ added in v0.5.0
type GuildNameParams ¶
type GuildNameParams struct {
Name string
}
type MediaPatterns ¶ added in v0.4.0
type MediaPatterns struct { Enabled bool `yaml:"enabled"` TplAttachments string `yaml:"attachments"` TplEmojis string `yaml:"emojis"` TplStickers string `yaml:"stickers"` TplAvatars string `yaml:"avatars"` // contains filtered or unexported fields }
func (*MediaPatterns) Attachment ¶ added in v0.4.0
func (mp *MediaPatterns) Attachment(channelID, attachmentID, filename string) id.ContentURI
func (*MediaPatterns) Avatar ¶ added in v0.4.0
func (mp *MediaPatterns) Avatar(userID, avatarID, ext string) id.ContentURI
func (*MediaPatterns) Emoji ¶ added in v0.4.0
func (mp *MediaPatterns) Emoji(emojiID, ext string) id.ContentURI
func (*MediaPatterns) Sticker ¶ added in v0.4.0
func (mp *MediaPatterns) Sticker(stickerID, ext string) id.ContentURI
func (*MediaPatterns) UnmarshalYAML ¶ added in v0.4.0
func (mp *MediaPatterns) UnmarshalYAML(unmarshal func(interface{}) error) error
Click to show internal directories.
Click to hide internal directories.