Skip to content

Instantly share code, notes, and snippets.

@CharlieEtienne
CharlieEtienne / CheckFilamentCompat.php
Last active June 22, 2025 03:48
Check if your Filament Plugins are ready for v4
<?php
namespace App\Console\Commands;
use Illuminate\Console\Command;
use Illuminate\Support\Facades\Http;
class CheckFilamentCompat extends Command
{
/**
<?php
declare(strict_types=1);
namespace App\Security\Authenticator;
use App\Exception\UserAuthenticationException;
use App\Repository\CustomerRepository;
use Psr\Log\LoggerInterface;
use Sylius\Component\User\Model\UserInterface as SyliusUserInterface;
@carstenwindler
carstenwindler / xdebug.sh
Last active June 20, 2025 18:18
Bash script to quickly enable / disable xdebug in a PHP docker container
#!/usr/bin/env bash
# see https://carstenwindler.de/php/enable-xdebug-on-demand-in-your-local-docker-environment/
if [ "$#" -ne 1 ]; then
SCRIPT_PATH=`basename "$0"`
echo "Usage: $SCRIPT_PATH enable|disable"
exit 1;
fi
# Expects service to be called app in docker-compose.yml
@ishan1608
ishan1608 / heater.py
Last active May 28, 2025 06:05
A python script to heat your computer so that your fingers can work upon your laptop in winter.
"""Heater
A program that spawns as much number of processes as there are CPUs on the computer.
This keeps the core temprature high.
I made this so that my fingers feel more comfortable while working on my laptop during winter.
Caution : An eye should be kept on the CPU temprature so that when it is getting too hot,
the prgoram needs to be killed; else it can damage the CPU.
Author : Ishan
Email : [email protected]
"""