Skip to content

Instantly share code, notes, and snippets.

View davidcralph's full-sized avatar
🐧

David Ralph davidcralph

🐧
View GitHub Profile
@TrillCyborg
TrillCyborg / mastodon-docker-setup.md
Last active May 14, 2025 02:50
Mastodon Docker Setup

Mastodon Docker Setup

Setting up

Clone Mastodon's repository.

# Clone mastodon to ~/live directory
git clone https://github.com/tootsuite/mastodon.git live
# Change directory to ~/live

cd ~/live

@fnky
fnky / ANSI.md
Last active July 2, 2025 04:57
ANSI Escape Codes

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27
@davidcralph
davidcralph / rules.txt
Last active March 26, 2022 11:52
DBL Adblocker Rules
discordbots.org###doublevoting
discordbots.org###medal
discordbots.org###bots > div.container.is-fullhd:first-child > div.bot-list-section:last-child > ul.columns.is-tablet:last-child > li.column.bot-card.is-one-fourth:last-child
discordbots.org###bots > div.container.is-fullhd:first-child > div.bot-list-section:last-child > ul.columns.is-tablet:first-child > li.column.bot-card.is-one-fourth:first-child
discordbots.org###bots > div.container.is-fullhd:nth-child(3) > div.bot-list-section:last-child > ul.columns.is-tablet:first-child > li.column.bot-card.is-one-fourth:first-child
discordbots.org###bots > div.container.is-fullhd:last-child > div.bot-list-section:last-child > ul.columns.is-tablet:first-child > li.column.bot-card.is-one-fourth:first-child
discordbots.org###bots > div.container.is-fullhd:last-child > div.bot-list-section:last-child > ul.columns.is-tablet:last-child > li.column.bot-card.is-one-fourth:last-child
discordbots.org###bot-list > div.bot-list-section > ul.columns.is-multiline.is-tablet > l
@mutin-sa
mutin-sa / Top_Public_Time_Servers.md
Last active July 1, 2025 05:23
List of Top Public Time Servers

Google Public NTP [AS15169]:

time.google.com

time1.google.com

time2.google.com

time3.google.com

@thomasbnt
thomasbnt / code_colors_discordjs.md
Last active May 20, 2025 15:16
Code colors for embed discord.js

Here is an updated list of the colors that are currently implemented with a name. To using colors on discord.js, this is a typedef Colors, Colors.Aqua to get the Aqua color.

Name Int value Hex Code
Default 0 #000000
Aqua 1752220 #1ABC9C
DarkAqua 1146986 #11806A
Green 5763719 #57F287
DarkGreen 2067276 #1F8B4C
@Mo45
Mo45 / discord.msg.send.php
Last active May 31, 2025 13:34
PHP - Send message to Discord via Webhook
<?php
/**
* discord.msg.send.php v0.8
* Kirill Krasin &copy; 2025
* https://github.com/Mo45
*
* For revisions and comments vist: https://gist.github.com/Mo45/cb0813cb8a6ebcd6524f6a36d4f8862c
*
* Sends a message to Discord via Webhook with file support and rate limit handling
*
@timvisee
timvisee / falsehoods-programming-time-list.md
Last active July 1, 2025 17:29
Falsehoods programmers believe about time, in a single list

Falsehoods programmers believe about time

This is a compiled list of falsehoods programmers tend to believe about working with time.

Don't re-invent a date time library yourself. If you think you understand everything about time, you're probably doing it wrong.

Falsehoods

  • There are always 24 hours in a day.
  • February is always 28 days long.
  • Any 24-hour period will always begin and end in the same day (or week, or month).
@blueskythlikesclouds
blueskythlikesclouds / SFPac.md
Last active January 15, 2023 14:32
Sonic Forces PAC Packer/Unpacker

EXE Release

Download here.

Python Script

The script is attached to the gist.
You need Python 2.7.14 to run the script.
If you don't know what Python is, or simply don't want to install it, use the EXE version.

Notice

SFPac is very old and works only on Sonic Forces. I recommend using HedgeArcPack instead. It has better performance and supports more games.

@meew0
meew0 / apitosqa.md
Last active April 8, 2025 16:52
API ToS Q&A Summary

This is a summary of the Q&A regarding the new API ToS that took place in the #api channel on the Discord API server, starting around midnight UTC on Thursday, August 17, 2017.

All answers are from b1nzy unless marked otherwise. This is just a summary of my (meew0) own interpretation of the Q&A; obviously this shouldn't be interpreted as anything legally binding. If in doubt, ask the devs yourself or consult a lawyer. I'm not responsible if you get banned or sued because of this document. All subsequent usages of first-person pronouns refer to the people asking/answering the questions, respectively.

Q. How do we detect users deleting their accounts, if we have to delete their data within 7 days?
A. You will get an email by Discord if that happens. Make sure the account that registered the bot application has an email attached to it that you actually get messages with. This may change in the future but if it will, there will be plenty of time before the new mechanism goes into effect.

Q. **Do we need

@jaytaylor
jaytaylor / react-unexpected-use-of-location.md
Created July 12, 2017 22:44
Solution for "Unexpected use of 'location'" React error.
React: Unexpected use of 'location';

Solution: Use window.location instead of bare location.