Skip to content

Instantly share code, notes, and snippets.

View phecdaDia's full-sized avatar
🏳️‍🌈

Phecda phecdaDia

🏳️‍🌈
View GitHub Profile
@phecdaDia
phecdaDia / Cargo.toml
Created April 12, 2023 00:17
Command line video viewer
[package]
name = "cmd-movie"
version = "0.1.0"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
# Enable a small amount of optimization in debug mode
[profile.dev]
opt-level = 1
strip = 'none'
@phecdaDia
phecdaDia / template.php
Last active April 9, 2021 19:49
Redirect discord
<?php
$discord_user_agent = 'Mozilla/5.0 (compatible; Discordbot/2.0; +https://discordapp.com)';
$title = '';
$description = '';
$image_url = '';
$redirect_url = 'https://www.youtube.com/watch?v=dQw4w9WgXcQ';
$actual_link = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? "https" : "http") . "://".$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI'];
@phecdaDia
phecdaDia / hide-image.py
Last active January 14, 2024 13:02
Changing image on click in discord.
import matplotlib.pyplot as plt
# don't fucking ask me how this works
magic_header = """
00 00 00 04 67 41 4D 41 00 00 27 10 4C 57 C2 4C
00 00 00 20 63 48 52 4D 00 00 87 0B 00 00 8C 0F
00 00 FD 51 00 00 81 40 00 00 7D 76 00 00 E9 90
00 00 3C E5 00 00 19 CD 21 AE 5C 4A