Skip to content

Instantly share code, notes, and snippets.

View dingman's full-sized avatar

Jon Dingman dingman

View GitHub Profile
#!/usr/bin/env bash
# Prevent host-wide OOM stalls that drop Emdash SSH sessions.
# 1. Cap total memory for user 1000's systemd manager (agents, tmux tasks, timers)
# so SSH login sessions always keep headroom.
# 2. Install + enable systemd-oomd to kill runaway cgroups before the kernel stalls.
# 3. Lower vm.swappiness to reduce thrashing.
# Per-task caps (tmux-spawn-*.scope, breezy.slice) live in ~/.config/systemd/user/ and
# are applied separately without root.
#
# Usage: sudo ~/bin/harden-memory.sh apply
#!/bin/bash
#
# dangerclaude
#
# USAGE:
# dangerclaude
# -> creates a brand new session "superclaude-<timestamp>-<pid>" and attaches
#
# dangerclaude label
# -> creates (or reattaches to) session "superclaude-label"
function checkHttpStatus(url) {
if (!url) {
return 'No URL';
}
try {
var response = UrlFetchApp.fetch(url, {'muteHttpExceptions': true});
return response.getResponseCode();
} catch (e) {
return "Error";
Authored by @crswll
// Config
const inflatePlugin = function ({ addComponents, theme, variants, e }) {
const spacing = theme('spacing', {})
Object.entries(spacing).forEach(([name, padding]) => {
addComponents(
{
[`.${e(`inflate-${name}`)} > *`]: { padding },
Design
* https://www.colorbox.io/
This will be updated over time.
#!/usr/bin/env bash
# WP-CLI Back up Script to Amazon S3
# Source: https://www.jonathan.vc
# Author: Jonathan Dingman
# Adapted from Mike at WP Bullet
#define local path for backups
BACKUPPATH=/tmp/backups
#path to WordPress installations