Skip to content

Instantly share code, notes, and snippets.

View imeesa's full-sized avatar

Eesa imeesa

View GitHub Profile

github.ref vs github.head_ref in GitHub Actions

Trigger event pull_request pull_request_target push
github.ref refs/pull/53/merge refs/heads/main refs/heads/test/pull_request_target
github.head_ref test/pull_request_target test/pull_request_target -
  • main: default branch
  • test/pull_request_target: topic branch name
  • 53: pull request number
@pinheaded
pinheaded / cog_ext.py
Last active November 10, 2024 12:26
a basic cog + extension example for discord.py v2
from discord import app_commands
from discord.ext import commands
# all cogs inherit from this base class
class ExampleCog(commands.Cog):
def __init__(self, bot):
self.bot = bot # adding a bot attribute for easier access
# adding a command to the cog
@commands.command(name="ping")
{
"193.25.217.28": "WoodieScan",
"51.75.66.201": "slowstack",
"151.115.73.107": "matscan",
"154.213.185.46": "MC Server Scanner",
"154.213.187.114": "MC Server Scanner",
"3.14.29.73": "MC Server Scanner",
"154.213.187.131": "MYNX scanner",
"172.104.152.224": "mcsrvstat.us",
"94.131.100.102": "ServerOverflow",