Skip to content

Commit

Permalink
fix: use - instead of _ for command names (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
benw202 authored Jan 27, 2024
1 parent edfaf7e commit 1b91198
Show file tree
Hide file tree
Showing 13 changed files with 14 additions and 13 deletions.
1 change: 1 addition & 0 deletions .github/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

Update <small>_ January 2024</small>

- fix: use - instead of _ in command names (27/01/2024)
- feat: auto-generation of the command table (24/01/2024)
- feat: migrate reportedIssues command (22/01/2024)
- feat: docSearch command (22/01/2024)
Expand Down
2 changes: 1 addition & 1 deletion src/commands/moderation/cacheUpdate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { ApplicationCommandOptionType, ApplicationCommandType, Colors, EmbedFiel
import { constantsConfig, slashCommand, slashCommandStructure, makeEmbed } from '../../lib';

const data = slashCommandStructure({
name: 'cache_update',
name: 'cache-update',
description: 'Updates the cache of the bot for a specific cache type.',
type: ApplicationCommandType.ChatInput,
default_member_permissions: constantsConfig.commandPermission.MANAGE_SERVER, //Overrides need to be added for admin, moderator and bot developer roles
Expand Down
2 changes: 1 addition & 1 deletion src/commands/moderation/commandTable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { S3Client, PutObjectCommand } from '@aws-sdk/client-s3';
import { slashCommand, slashCommandStructure, Logger, constantsConfig } from '../../lib';

const data = slashCommandStructure({
name: 'generate_command_table',
name: 'generate-command-table',
description: 'Generates the command table.',
type: ApplicationCommandType.ChatInput,
default_member_permissions: constantsConfig.commandPermission.MANAGE_SERVER, //Overrides need to be added for admin, moderator bot developer and docs team roles
Expand Down
2 changes: 1 addition & 1 deletion src/commands/moderation/deployCommands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import contextArray from '../context/index';
import { client } from '../../client';

const data = slashCommandStructure({
name: 'deploy_commands',
name: 'deploy-commands',
description: 'Deploy commands to the server or globally.',
type: ApplicationCommandType.ChatInput,
default_member_permissions: constantsConfig.commandPermission.MANAGE_SERVER, //Overrides need to be added for admin, moderator and bot developer roles
Expand Down
2 changes: 1 addition & 1 deletion src/commands/moderation/faq/faq.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const data = slashCommandStructure({
type: ApplicationCommandOptionType.Subcommand,
},
{
name: 'print_all',
name: 'print-all',
description: 'Prints all FAQs.',
type: ApplicationCommandOptionType.Subcommand,
},
Expand Down
2 changes: 1 addition & 1 deletion src/commands/moderation/roleAssignment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
import { constantsConfig, makeEmbed, slashCommand, slashCommandStructure } from '../../lib';

const data = slashCommandStructure({
name: 'role_assignment',
name: 'role-assignment',
description: 'Configures and sends the role assignment embed.',
type: ApplicationCommandType.ChatInput,
default_member_permissions: constantsConfig.commandPermission.MANAGE_SERVER, //Overrides need to be added for admin and moderator
Expand Down
2 changes: 1 addition & 1 deletion src/commands/utils/docSearch.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import Filter from 'bad-words';
import { slashCommand, slashCommandStructure, makeEmbed } from '../../lib';

const data = slashCommandStructure({
name: 'doc_search',
name: 'doc-search',
description: 'Searches the FlyByWire Documentation for a given query.',
type: ApplicationCommandType.ChatInput,
options: [{
Expand Down
2 changes: 1 addition & 1 deletion src/commands/utils/liveFlights.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { ApplicationCommandType, Colors } from 'discord.js';
import { slashCommand, slashCommandStructure, makeEmbed, Logger } from '../../lib';

const data = slashCommandStructure({
name: 'live_flights',
name: 'live-flights',
description: 'Get the current live flights for FlyByWire Simulations.',
type: ApplicationCommandType.ChatInput,
});
Expand Down
2 changes: 1 addition & 1 deletion src/commands/utils/memberCount.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { ApplicationCommandType } from 'discord.js';
import { slashCommand, slashCommandStructure, makeEmbed } from '../../lib';

const data = slashCommandStructure({
name: 'member_count',
name: 'member-count',
description: 'Lists the current member count for the server.',
type: ApplicationCommandType.ChatInput,
});
Expand Down
2 changes: 1 addition & 1 deletion src/commands/utils/reportedIssues.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { JSDOM } from 'jsdom';
import { Logger, makeEmbed, slashCommand, slashCommandStructure } from '../../lib';

const data = slashCommandStructure({
name: 'reported_issues',
name: 'reported-issues',
description: 'Provides a link to the reported issues page within docs.',
type: ApplicationCommandType.ChatInput,
options: [{
Expand Down
2 changes: 1 addition & 1 deletion src/commands/utils/roleInfo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { ApplicationCommandOptionType, ApplicationCommandType } from 'discord.js
import { slashCommand, slashCommandStructure, makeEmbed } from '../../lib';

const data = slashCommandStructure({
name: 'role_info',
name: 'role-info',
description: 'Lists the given role\'s amount of members.',
type: ApplicationCommandType.ChatInput,
options: [{
Expand Down
2 changes: 1 addition & 1 deletion src/commands/utils/searchFaq.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { ApplicationCommandOptionType, ApplicationCommandType } from 'discord.js
import { constantsConfig, slashCommand, slashCommandStructure, makeEmbed, FAQ, Logger } from '../../lib';

const data = slashCommandStructure({
name: 'faq_search',
name: 'faq-search',
description: 'Searches the FAQs.',
type: ApplicationCommandType.ChatInput,
options: [
Expand Down
4 changes: 2 additions & 2 deletions src/commands/utils/simbriefData.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import moment from 'moment';
import { slashCommand, makeEmbed, makeLines, slashCommandStructure } from '../../lib';

const data = slashCommandStructure({
name: 'simbrief_data',
name: 'simbrief-data',
description: 'Gets the simbrief data for the given flight number/pilotID.',
type: ApplicationCommandType.ChatInput,
options: [
Expand All @@ -20,7 +20,7 @@ const data = slashCommandStructure({
}],
},
{
name: 'support_request',
name: 'support-request',
description: 'Shows information on how to provide SimBrief data.',
type: ApplicationCommandOptionType.Subcommand,
},
Expand Down

0 comments on commit 1b91198

Please sign in to comment.