Skip to content

Instantly share code, notes, and snippets.

View godismyjudge95's full-sized avatar

Daniel Weaver godismyjudge95

View GitHub Profile
@markshust
markshust / README.md
Last active January 13, 2026 17:59
Zero-downtime Laravel deployment with GitHub Actions

GitHub Actions Deploy Script - Environment Variables Setup Guide

This guide explains how to set up the required environment variables (GitHub Secrets) for the Laravel deployment GitHub Actions workflow.

Overview

The deployment script uses GitHub Secrets to securely store sensitive information like SSH keys and server details. These secrets are referenced in the workflow using the ${{ secrets.SECRET_NAME }} syntax.

Required Secrets

@conradfuhrman
conradfuhrman / herd-reverb-ssl.md
Last active June 19, 2025 14:02
Laravel Herd, SSL, and Reverb with Herd

Currently validated through Herd 1.9.1. Last Updated August 7th, 2024

There are a few options to get Herd/Reverb working with SSL & across your local network among other devices:

  • Use a dedicated reverb domain (reverb.test)
  • Integrate it into your existing domain (mynewcoolsite.test)
  • Open it up to your local Network.

Use a Dedicated Reverb Domain

The biggest issue with Herd Pro is that you cannot use Reverb out of the box with a site that has SSL enabled. Here is the workaround for it all to play nicely together.

@OrionReed
OrionReed / dom3d.js
Last active February 6, 2026 16:33
3D DOM viewer, copy-paste this into your console to visualise the DOM topographically.
// 3D Dom viewer, copy-paste this into your console to visualise the DOM as a stack of solid blocks.
// You can also minify and save it as a bookmarklet (https://www.freecodecamp.org/news/what-are-bookmarklets/)
(() => {
const SHOW_SIDES = false; // color sides of DOM nodes?
const COLOR_SURFACE = true; // color tops of DOM nodes?
const COLOR_RANDOM = false; // randomise color?
const COLOR_HUE = 190; // hue in HSL (https://hslpicker.com)
const MAX_ROTATION = 180; // set to 360 to rotate all the way round
const THICKNESS = 20; // thickness of layers
const DISTANCE = 10000; // ¯\\_(ツ)_/¯
@simonhamp
simonhamp / MigrateUsers.php
Last active June 12, 2025 07:10
Migrate Statamic v3 file-based users to a database
<?php
/**
* Statamic v3 User Migrator
* @author Simon Hamp <[email protected]>
* @copyright Copyright (c) 2021, Simon Hamp
* @license MIT
*/
namespace App\Console\Commands;
use Exception;
@amir9480
amir9480 / helpers.php
Last active May 7, 2024 16:03
Laravel copy all files from one storage disk to another
<?php
if (! function_exists("copy_storage")) {
/**
* Copy files from one disk to another.
*
* @param string $from from disk name
* @param string $to to disk name
* @param string $directory if you want just copy specific directory
* @return void
@Dimimo
Dimimo / LinodeCopy.php
Last active May 15, 2024 16:03
A Laravel artisan command to help move your files from S3 to Linode
<?php
namespace App\Console\Commands;
use Illuminate\Console\Command;
use Storage;
class LinodeCopy extends Command
{
/**
@laravel-shift
laravel-shift / .php-cs-fixer.php
Last active January 15, 2026 09:58
PHP CS Fixer - Laravel Coding Style Ruleset
<?php
use PhpCsFixer\Config;
use PhpCsFixer\Finder;
$rules = [
'array_indentation' => true,
'array_syntax' => ['syntax' => 'short'],
'binary_operator_spaces' => [
'default' => 'single_space',
@troglodyne
troglodyne / cP_clevel_mongler.pl
Last active February 17, 2022 20:55
[cPanel] Perl Mechanize script for setting all /var/cpanel/clevels.conf values at once
use strict;
use warnings;
use WWW::Mechanize;
use Term::ReadKey;
use Getopt::Long;
# Get options
my ( $host, $password, %opts );
GetOptions(