Skip to content

Instantly share code, notes, and snippets.

View Zeryther's full-sized avatar
🎯

Zeryther Zeryther

🎯
View GitHub Profile
@Greydus
Greydus / Yoshino.js
Last active January 20, 2022 04:21
Replaces all YouTube embed URLs
// ==UserScript==
// @name Yoshino
// @namespace moe.greydus
// @version 2.28.0
// @description Replaces all YouTube embed URLs
// @match *://*/*
// @exclude-match https://www.youtube.com/*
// ==/UserScript==
var iframe_list = document.querySelectorAll('iframe[src*="www.youtube.com"]');
@krisleech
krisleech / renew-gpgkey.md
Last active December 3, 2025 23:51
Renew Expired GPG key

Renew GPG key

Given that your key has expired.

$ gpg --list-keys
$ gpg --edit-key KEYID

Use the expire command to set a new expire date:

@Redoishi
Redoishi / AMyCommand.java
Last active July 21, 2022 19:22
Create a minecraft command without plugin.yml
package your.package;
import org.bukkit.Bukkit;
import org.bukkit.ChatColor;
import org.bukkit.command.*;
import org.bukkit.plugin.java.JavaPlugin;
import java.lang.reflect.Field;
import java.util.ArrayList;
import java.util.Arrays;
@atillay
atillay / DemoController.php
Last active July 24, 2024 17:19
Symfony 4 Pagination Service
<?php
namespace App\Controller;
use App\Entity\Demo;
use App\Service\PaginationService;
use Symfony\Component\HttpFoundation\Request;
class DemoController extends AdminController
{
@fieg
fieg / LoginController.php
Last active October 18, 2023 11:01
Symfony4 Login Form Type
<?php
use LoginType;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route;
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Template;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
final class LoginController extends Controller
{
/**
@ikawka
ikawka / cloudflare-trace.js
Last active December 31, 2023 12:29
Trace current user's location via javascript with CloudFlare provided the /cdn-cgi/trace is enabled.
(function($){
$(function(){
$.ajax({
contentType: 'application/text; charset=utf-8',
crossBrowser: true,
type: 'GET',
url: '/cdn-cgi/trace',
}).done(function(d){
var data = d.replace(/[\r\n]+/g, '","').replace(/\=+/g, '":"');
data = '{"' + data.slice(0, data.lastIndexOf('","')) + '"}';
@poisa
poisa / Readme.md
Created August 21, 2017 17:11 — forked from StefanieD/Readme.md
Install and use Supervisord with AWS Elastic Beanstalk, Symfony 2 and RabbitMq Bundle
  • Place the supervisord.conf under .ebextensions/supervisor/

  • Place the supervisor.config under .ebextensions/

  • Place the data_import_consumer.conf under .ebextensions/supervisor/

@a7madgamal
a7madgamal / Kaomoji.txt
Last active July 6, 2024 06:12
┬┴┬┴┤( ͡° ͜ʖ├┬┴┬┴
Joy
(^ω^)
(-‿‿-)
(o^▽^o)
(⌒▽⌒)☆
<( ̄︶ ̄)>
ヽ(・∀・)ノ
(´。• ω •。`)
( ̄ω ̄)
@nrollr
nrollr / nginx.conf
Last active November 14, 2025 02:31
NGINX config for SSL with Let's Encrypt certs
# UPDATED 17 February 2019
# Redirect all HTTP traffic to HTTPS
server {
listen 80;
listen [::]:80;
server_name www.domain.com domain.com;
return 301 https://$host$request_uri;
}
# SSL configuration
@PimDeWitte
PimDeWitte / Efficient Bad Word Filter
Last active June 30, 2025 17:53
Simple profanity filter written in Java for efficient comparison. Runtime grows based on string input, not list size.
static Map<String, String[]> words = new HashMap<>();
static int largestWordLength = 0;
public static void loadConfigs() {
try {
BufferedReader reader = new BufferedReader(new InputStreamReader(new URL("https://docs.google.com/spreadsheets/d/1hIEi2YG3ydav1E06Bzf2mQbGZ12kh2fe4ISgLg_UBuM/export?format=csv").openConnection().getInputStream()));
String line = "";
int counter = 0;
while((line = reader.readLine()) != null) {