From 7f169ad3eb564a6508ac0460b36d217fb4f269e3 Mon Sep 17 00:00:00 2001 From: Abigail Gold Date: Sat, 7 Dec 2019 17:26:55 -0500 Subject: [PATCH] rename "cogs" to extensions (more accurate!) --- cogs/ae7qcog.py => exts/ae7qext.py | 2 +- cogs/basecog.py => exts/baseext.py | 2 +- cogs/funcog.py => exts/funext.py | 2 +- cogs/gridcog.py => exts/gridext.py | 2 +- cogs/hamcog.py => exts/hamext.py | 2 +- cogs/imagecog.py => exts/imageext.py | 2 +- cogs/morsecog.py => exts/morseext.py | 2 +- cogs/qrzcog.py => exts/qrzext.py | 2 +- cogs/studycog.py => exts/studyext.py | 2 +- cogs/weathercog.py => exts/weatherext.py | 2 +- main.py | 7 +++---- templates/data/options.py | 6 +++--- 12 files changed, 16 insertions(+), 17 deletions(-) rename cogs/ae7qcog.py => exts/ae7qext.py (99%) rename cogs/basecog.py => exts/baseext.py (99%) rename cogs/funcog.py => exts/funext.py (97%) rename cogs/gridcog.py => exts/gridext.py (99%) rename cogs/hamcog.py => exts/hamext.py (99%) rename cogs/imagecog.py => exts/imageext.py (99%) rename cogs/morsecog.py => exts/morseext.py (99%) rename cogs/qrzcog.py => exts/qrzext.py (99%) rename cogs/studycog.py => exts/studyext.py (99%) rename cogs/weathercog.py => exts/weatherext.py (99%) diff --git a/cogs/ae7qcog.py b/exts/ae7qext.py similarity index 99% rename from cogs/ae7qcog.py rename to exts/ae7qext.py index 8e94690..015808c 100644 --- a/cogs/ae7qcog.py +++ b/exts/ae7qext.py @@ -1,5 +1,5 @@ """ -ae7q cog for qrm +ae7q extension for qrm --- Copyright (C) 2019 Abigail Gold, 0x5c diff --git a/cogs/basecog.py b/exts/baseext.py similarity index 99% rename from cogs/basecog.py rename to exts/baseext.py index 290a8cd..875058b 100644 --- a/cogs/basecog.py +++ b/exts/baseext.py @@ -1,5 +1,5 @@ """ -Base cog for qrm +Base extension for qrm --- Copyright (C) 2019 Abigail Gold, 0x5c diff --git a/cogs/funcog.py b/exts/funext.py similarity index 97% rename from cogs/funcog.py rename to exts/funext.py index 5662b0f..f7352ba 100644 --- a/cogs/funcog.py +++ b/exts/funext.py @@ -1,5 +1,5 @@ """ -Fun cog for qrm +Fun extension for qrm --- Copyright (C) 2019 Abigail Gold, 0x5c diff --git a/cogs/gridcog.py b/exts/gridext.py similarity index 99% rename from cogs/gridcog.py rename to exts/gridext.py index 5e5f9dd..e8ca466 100644 --- a/cogs/gridcog.py +++ b/exts/gridext.py @@ -1,5 +1,5 @@ """ -Grid cog for qrm +Grid extension for qrm --- Copyright (C) 2019 Abigail Gold, 0x5c diff --git a/cogs/hamcog.py b/exts/hamext.py similarity index 99% rename from cogs/hamcog.py rename to exts/hamext.py index 58ede8e..22b979d 100644 --- a/cogs/hamcog.py +++ b/exts/hamext.py @@ -1,5 +1,5 @@ """ -Ham cog for qrm +Ham extension for qrm --- Copyright (C) 2019 Abigail Gold, 0x5c diff --git a/cogs/imagecog.py b/exts/imageext.py similarity index 99% rename from cogs/imagecog.py rename to exts/imageext.py index 51d4d7b..1056957 100644 --- a/cogs/imagecog.py +++ b/exts/imageext.py @@ -1,5 +1,5 @@ """ -Image cog for qrm +Image extension for qrm --- Copyright (C) 2019 Abigail Gold, 0x5c diff --git a/cogs/morsecog.py b/exts/morseext.py similarity index 99% rename from cogs/morsecog.py rename to exts/morseext.py index 0ba8ab0..4b84ff4 100644 --- a/cogs/morsecog.py +++ b/exts/morseext.py @@ -1,5 +1,5 @@ """ -Morse Code cog for qrm +Morse Code extension for qrm --- Copyright (C) 2019 Abigail Gold, 0x5c diff --git a/cogs/qrzcog.py b/exts/qrzext.py similarity index 99% rename from cogs/qrzcog.py rename to exts/qrzext.py index 1a18a94..7267edd 100644 --- a/cogs/qrzcog.py +++ b/exts/qrzext.py @@ -1,5 +1,5 @@ """ -QRZ cog for qrm +QRZ extension for qrm --- Copyright (C) 2019 Abigail Gold, 0x5c diff --git a/cogs/studycog.py b/exts/studyext.py similarity index 99% rename from cogs/studycog.py rename to exts/studyext.py index b72348c..e19b12d 100644 --- a/cogs/studycog.py +++ b/exts/studyext.py @@ -1,5 +1,5 @@ """ -Study cog for qrm +Study extension for qrm --- Copyright (C) 2019 Abigail Gold, 0x5c diff --git a/cogs/weathercog.py b/exts/weatherext.py similarity index 99% rename from cogs/weathercog.py rename to exts/weatherext.py index 4be5317..a72e806 100644 --- a/cogs/weathercog.py +++ b/exts/weatherext.py @@ -1,5 +1,5 @@ """ -Weather cog for qrm +Weather extension for qrm --- Copyright (C) 2019 Abigail Gold, 0x5c diff --git a/main.py b/main.py index 449dc4a..62cbf68 100644 --- a/main.py +++ b/main.py @@ -25,7 +25,7 @@ from data import keys exit_code = 1 # The default exit code. ?shutdown and ?restart will change it accordingly (fail-safe) -ext_dir = "cogs" # The name of the directory where extensions are located. +ext_dir = "exts" # The name of the directory where extensions are located. debug_mode = opt.debug # Separate assignement in-case we define an override (ternary operator goes here) @@ -149,9 +149,8 @@ async def _before_ensure_activity(): # --- Run --- -# bot.add_cog(GlobalSettings(bot)) -for cog in opt.cogs: - bot.load_extension(f"cogs.{cog}") +for ext in opt.exts: + bot.load_extension(f"exts.{ext}") _ensure_activity.start() diff --git a/templates/data/options.py b/templates/data/options.py index 8c60b01..c3a7351 100644 --- a/templates/data/options.py +++ b/templates/data/options.py @@ -26,9 +26,9 @@ debug = False # ! This MUST be a tuple of integers. Single element tuple: `(123,)` owners_uids = (200102491231092736,) -# The cogs to load when running the bot. -cogs = ['basecog', 'morsecog', 'funcog', 'gridcog', 'hamcog', 'imagecog', - 'studycog', 'ae7qcog', 'qrzcog', 'weathercog'] +# The extensions to load when running the bot. +exts = ['ae7qext', 'baseext', 'funext', 'gridext', 'hamext', 'imageext', + 'morseext', 'qrzext', 'studyext', 'weatherext'] # The text to put in the "playing" status. game = 'with lids on 7.200'