Skip to content

Instantly share code, notes, and snippets.

View jacurtis's full-sized avatar

J. Alexander Curtis jacurtis

View GitHub Profile
@jacurtis
jacurtis / forge.sh
Created April 27, 2019 05:29
Laravel Forge Setup Script
#
# REQUIRES:
# - server (the forge server instance)
# - event (the forge event instance)
# - sudo_password (random password for sudo)
# - db_password (random password for database user)
# - callback (the callback URL)
#
@jacurtis
jacurtis / gist:fb19e36177c5cc575d9b006385ae64d1
Created August 26, 2022 00:29 — forked from AlexanderRD/gist:485f12395cc30f3444b7
Delete all git branches with prefix
git branch -D `git branch | grep 'ard_*'`
@jacurtis
jacurtis / aws_json.py
Last active December 1, 2021 12:42 — forked from jeffbrl/describe_instances.py
How to make boto3 responses with datetime.datetime json serializable - boto3 ec2 describe_instances or rds describe_db_instances
# The file that does the voodoo magic
# Inspired by:
# - https://stackoverflow.com/questions/35869985/datetime-datetime-is-not-json-serializable
# - https://gist.github.com/jeffbrl/67eed588f2d32afcaf3bf779bd91f7a7
import json
import datetime
def pretty_print(data):
print(json.dumps(data, default=__datetime_handler, indent=4))