Skip to content

Instantly share code, notes, and snippets.

@0atman
0atman / configuration.nix
Last active October 22, 2025 15:06
A rebuild script that commits on a successful build
{
config,
pkgs,
options,
...
}: let
hostname = "oatman-pc"; # to alllow per-machine config
in {
networking.hostName = hostname;
@bradtraversy
bradtraversy / mysql_cheat_sheet.md
Last active November 1, 2025 12:16
MySQL Cheat Sheet

MySQL Cheat Sheet

Help with SQL commands to interact with a MySQL database

MySQL Locations

  • Mac /usr/local/mysql/bin
  • Windows /Program Files/MySQL/MySQL version/bin
  • Xampp /xampp/mysql/bin

Add mysql to your PATH

#! /usr/bin/env bash
# Skip all of this if we don't have a TTY
tty -s || return 0
# Colors + \[...\] wrapping to ensure there's no odd wrapping on command line
C_OFF="\[$(tput sgr0)\]"
C_BOLD="\[$(tput bold)\]"
C_BLACK="\[$(tput setaf 0)\]"
C_RED="\[$(tput setaf 1)\]"