Skip to content

Instantly share code, notes, and snippets.

View macprince's full-sized avatar

Dan Kuehling macprince

  • Huntley Community School District 158
  • IL, USA
View GitHub Profile
@macprince
macprince / M1iMacXCredsWallpaper.py
Last active September 15, 2023 05:36
This script will dynamically override the settings for XCreds to set the login screen wallpaper on your M1 iMacs to the proper color "hello" wallpaper for that color of iMac.
#!/usr/local/bin/managed_python3
import re
import plistlib
import subprocess
colors = {
"1": "Grey",
"3": "Yellow",
"4": "Green",
@macprince
macprince / Mist-Sync.sh
Created October 28, 2022 16:43
Script for downloading all available installers and firmware using mist-cli
#!/bin/sh
path="/Users/Shared/Mist"
mkdir -p $path/app $path/ipsw
apps=`mist list installer -o csv -q | awk -F "," '{gsub(/["=]/, "", $4);if (NR!=1){print $4}}' | sort -r`
ipsws=`mist list firmware -o csv -q | awk -F "," '{gsub(/["=]/, "", $4);if (NR!=1){print $4}}' | sort -r`
for build in $apps
do
@macprince
macprince / phonetic.md
Last active August 20, 2019 04:17
Clipboard Phonetic Alphabet for Text Expansion
@macprince
macprince / SchoolGrades.rb
Created August 10, 2017 04:30
Returns a list of the graduation years for students in a given grade this year.
#!/usr/bin/env ruby
%w[date].each{|lib| require lib}
class Integer
def ordinal
cardinal = self.abs
digit = cardinal%10
if (1..3).include?(digit) and not (11..13).include?(cardinal%100)
self.to_s << %w{st nd rd}[digit-1]
else
self.to_s << 'th'
@macprince
macprince / Manifesto.txt
Last active March 19, 2024 23:46
My IT Manifesto
I will work with you to figure out what the thing is that you need,
I will get the thing ordered for you,
I will unbox the thing and set it up for you,
I will help you get started using the thing,
I will maintain the thing in proper working order for you,
I will troubleshoot the thing for you,
I will fix the thing for you (if I can, or find someone who can if I can't),
I will properly dispose of the thing for you when it's no longer useful,
I will replace the thing with another, possibly better thing when the time comes.