Skip to content

Instantly share code, notes, and snippets.

View Arthurdw's full-sized avatar
:shipit:
Whachu doing?

Arthur Arthurdw

:shipit:
Whachu doing?
View GitHub Profile
@Arthurdw
Arthurdw / docker-compose.yml
Created October 7, 2023 14:29
CasaMate directus CMS
version: '3'
services:
database:
image: postgis/postgis:13-master
# Required when running on platform other than amd64, like Apple M1/M2:
# platform: linux/amd64
volumes:
- ./data/database:/var/lib/postgresql/data
environment:
POSTGRES_USER: 'directus'
@Arthurdw
Arthurdw / current_command_implementation.py
Created September 2, 2021 15:18
Current command implementation for Pincer
from typing import List, Dict, Any
from pincer.client import Client, middleware
from pincer.core.dispatch import GatewayDispatch
from pincer.core.http import HTTPClient
say_cmd = {
"name": "say",
"type": 1,
"description": "Send a message",
@Arthurdw
Arthurdw / run.py
Created September 16, 2020 13:51
Adding a event listener
from typing import Optional
from discord import Member
from discord.ext.commands import command, Bot, Context
from utilsx.discord import BotX, Cog
BOT_TOKEN = "XXXYOURBOTTOKENHEREXXX"
class MyBot(BotX):
def __init__(self):
@Arthurdw
Arthurdw / run.py
Created September 16, 2020 13:26
A basic kick command
from typing import Optional
from discord import Member
from discord.ext.commands import command, Bot, Context
from utilsx.discord import BotX, Cog
BOT_TOKEN = "XXXYOURBOTTOKENHEREXXX"
class MyBot(BotX):
def __init__(self):
@Arthurdw
Arthurdw / run.py
Created September 16, 2020 12:05
A basic hello command
from discord.ext.commands import command, Bot, Context
from utilsx.discord import BotX, Cog
BOT_TOKEN = "XXXYOURBOTTOKENHEREXXX"
class MyBot(BotX):
def __init__(self):
super().__init__()
self.add_cog(CustomCommands(self))
@Arthurdw
Arthurdw / run.py
Created September 16, 2020 11:55
Putting your bot online!
from utilsx.discord import BotX
BOT_TOKEN = "XXXYOURBOTTOKENHEREXXX"
class MyBot(BotX):
pass
if __name__ == "__main__":