3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-10 12:25:02 +00:00

Formatting and initial ButtonRoles DB work

This commit is contained in:
Dark 2021-06-08 02:23:30 +02:00
parent 6ac9d2f2a2
commit 5efdf5ce95
No known key found for this signature in database
GPG key ID: 2CD6ACB6B0A87B8A
108 changed files with 253 additions and 303 deletions

View file

@ -8,7 +8,6 @@ import { EmbedWith, multiSorter, resolveMember, sorter } from "../../../utils";
import { TimeAndDatePlugin } from "../../TimeAndDate/TimeAndDatePlugin";
import { utilityCmd } from "../types";
export const AboutCmd = utilityCmd({
trigger: "about",
description: "Show information about Zeppelin's status on the server",

View file

@ -10,7 +10,6 @@ import { allowTimeout } from "../../../RegExpRunner";
import { DAYS, getInviteCodesInString, noop, SECONDS, stripObjectToScalars } from "../../../utils";
import { utilityCmd, UtilityPluginType } from "../types";
const MAX_CLEAN_COUNT = 150;
const MAX_CLEAN_TIME = 1 * DAYS;
const CLEAN_COMMAND_DELETE_DELAY = 5 * SECONDS;

View file

@ -5,7 +5,6 @@ import { messageLink } from "../../../utils";
import { canReadChannel } from "../../../utils/canReadChannel";
import { utilityCmd } from "../types";
export const ContextCmd = utilityCmd({
trigger: "context",
description: "Get a link to the context of the specified message",

View file

@ -2,7 +2,6 @@ import { TextChannel } from "discord.js";
import { activeReloads } from "../guildReloads";
import { utilityCmd } from "../types";
export const ReloadGuildCmd = utilityCmd({
trigger: "reload_guild",
description: "Reload the Zeppelin configuration and all plugins for the server. This can sometimes fix issues.",

View file

@ -5,7 +5,6 @@ import { chunkArray, sorter, trimLines } from "../../../utils";
import { refreshMembersIfNeeded } from "../refreshMembers";
import { utilityCmd } from "../types";
export const RolesCmd = utilityCmd({
trigger: "roles",
description: "List all roles or roles matching a search",

View file

@ -4,7 +4,6 @@ import { getBaseUrl, sendErrorMessage } from "../../../pluginUtils";
import { canReadChannel } from "../../../utils/canReadChannel";
import { utilityCmd } from "../types";
export const SourceCmd = utilityCmd({
trigger: "source",
description: "View the message source of the specified message id",

View file

@ -2,12 +2,9 @@ import { VoiceChannel } from "discord.js";
import { commandTypeHelpers as ct } from "../../../commandTypes";
import { LogType } from "../../../data/LogType";
import { canActOn, sendErrorMessage, sendSuccessMessage } from "../../../pluginUtils";
import {
stripObjectToScalars
} from "../../../utils";
import { stripObjectToScalars } from "../../../utils";
import { utilityCmd } from "../types";
export const VcdisconnectCmd = utilityCmd({
trigger: ["vcdisconnect", "vcdisc", "vcdc", "vckick", "vck"],
description: "Disconnect a member from their voice channel",

View file

@ -2,17 +2,9 @@ import { VoiceChannel } from "discord.js";
import { commandTypeHelpers as ct } from "../../../commandTypes";
import { LogType } from "../../../data/LogType";
import { canActOn, sendErrorMessage, sendSuccessMessage } from "../../../pluginUtils";
import {
channelMentionRegex,
isSnowflake,
simpleClosestStringMatch,
stripObjectToScalars
} from "../../../utils";
import { channelMentionRegex, isSnowflake, simpleClosestStringMatch, stripObjectToScalars } from "../../../utils";
import { utilityCmd } from "../types";
export const VcmoveCmd = utilityCmd({
trigger: "vcmove",
description: "Move a member to another voice channel",

View file

@ -7,7 +7,6 @@ import { EmbedWith, formatNumber, preEmbedPadding, trimLines } from "../../../ut
import { TimeAndDatePlugin } from "../../TimeAndDate/TimeAndDatePlugin";
import { UtilityPluginType } from "../types";
const TEXT_CHANNEL_ICON =
"https://cdn.discordapp.com/attachments/740650744830623756/740656843545772062/text-channel.png";
const VOICE_CHANNEL_ICON =

View file

@ -4,21 +4,19 @@ import { GuildPluginData } from "knub";
import moment from "moment-timezone";
import { ChannelTypeStrings } from "src/types";
import {
EmbedWith,
formatNumber,
GroupDMInvite,
inviteHasCounts,
isGroupDMInvite,
isGuildInvite,
preEmbedPadding,
resolveInvite,
trimLines
EmbedWith,
formatNumber,
GroupDMInvite,
inviteHasCounts,
isGroupDMInvite,
isGuildInvite,
preEmbedPadding,
resolveInvite,
trimLines,
} from "../../../utils";
import { snowflakeToTimestamp } from "../../../utils/snowflakeToTimestamp";
import { UtilityPluginType } from "../types";
export async function getInviteInfoEmbed(
pluginData: GuildPluginData<UtilityPluginType>,
inviteCode: string,

View file

@ -8,7 +8,6 @@ import { chunkMessageLines, EmbedWith, messageLink, preEmbedPadding, trimEmptyLi
import { TimeAndDatePlugin } from "../../TimeAndDate/TimeAndDatePlugin";
import { UtilityPluginType } from "../types";
const MESSAGE_ICON = "https://cdn.discordapp.com/attachments/740650744830623756/740685652152025088/message.png";
export async function getMessageInfoEmbed(

View file

@ -3,21 +3,20 @@ import humanizeDuration from "humanize-duration";
import { GuildPluginData } from "knub";
import moment from "moment-timezone";
import {
EmbedWith,
formatNumber,
inviteHasCounts,
memoize,
MINUTES,
preEmbedPadding,
resolveInvite,
resolveUser,
trimLines
EmbedWith,
formatNumber,
inviteHasCounts,
memoize,
MINUTES,
preEmbedPadding,
resolveInvite,
resolveUser,
trimLines,
} from "../../../utils";
import { TimeAndDatePlugin } from "../../TimeAndDate/TimeAndDatePlugin";
import { UtilityPluginType } from "../types";
import { getGuildPreview } from "./getGuildPreview";
export async function getServerInfoEmbed(
pluginData: GuildPluginData<UtilityPluginType>,
serverId: string,

View file

@ -2,9 +2,7 @@ import { MessageEmbedOptions } from "discord.js";
import humanizeDuration from "humanize-duration";
import { GuildPluginData } from "knub";
import moment from "moment-timezone";
import {
EmbedWith, preEmbedPadding
} from "../../../utils";
import { EmbedWith, preEmbedPadding } from "../../../utils";
import { snowflakeToTimestamp } from "../../../utils/snowflakeToTimestamp";
import { TimeAndDatePlugin } from "../../TimeAndDate/TimeAndDatePlugin";
import { UtilityPluginType } from "../types";

View file

@ -4,10 +4,14 @@ import { GuildPluginData } from "knub";
import moment from "moment-timezone";
import { CaseTypes } from "../../../data/CaseTypes";
import {
EmbedWith, messageLink, preEmbedPadding, resolveMember,
resolveUser,
sorter, trimLines, UnknownUser
EmbedWith,
messageLink,
preEmbedPadding,
resolveMember,
resolveUser,
sorter,
trimLines,
UnknownUser,
} from "../../../utils";
import { TimeAndDatePlugin } from "../../TimeAndDate/TimeAndDatePlugin";
import { UtilityPluginType } from "../types";