Skip to content

Instantly share code, notes, and snippets.


gregory nicholas gregorynicholas

View GitHub Profile
View gist:8e8454c03fec0b240480dff4e7d14ec1
#!/usr/bin/env python
# To look at:
# To look at:
Playing around with CoreWLAN to return information about the wi-fi connection
gregorynicholas /
Created Oct 3, 2019 — forked from pudquick/
Using PrivateFrameworks to get marketing model information for Apple Macs without hitting their internet API (where possible) via python and pyobjc
# Tested on 10.11
# Note:
# The marketing information embedded in the ServerInformation.framework is not the same as what
# About This Mac displays - there are differences.
# For example:
# ServerInformation: 15" MacBook Pro with Retina display (Mid 2015)
# About This Mac: MacBook Pro (Retina, 15-inch, Mid 2015)
gregorynicholas /
Created Oct 3, 2019 — forked from erikng/
Make standalone "universal" FirmwareUpdater package for High Sierra
# Based on investigations and work by Pepijn Bruienne
# Expects a single /Applications/Install macOS Sierra*.app on disk
# Adapted from
# find the Install macOS and mount the embedded InstallESD disk image
echo "Mounting Sierra ESD disk image..."
gregorynicholas /
Created Oct 3, 2019 — forked from pookjw/
Enroll macOS Beta Seed without profile installation


Enroll macOS Beta Seed without profile installation


$ sudo /System/Library/PrivateFrameworks/Seeding.framework/Versions/A/Resources/seedutil 
usage: seedutil enroll SEED_PROGRAM
    seedutil unenroll
    seedutil current
gregorynicholas /
Created Oct 3, 2019 — forked from albertbori/
Automatically disable Wifi when an Ethernet connection (cable) is plugged in on a Mac


This is a bash script that will automatically turn your wifi off if you connect your computer to an ethernet connection and turn wifi back on when you unplug your ethernet cable/adapter. If you decide to turn wifi on for whatever reason, it will remember that choice. This was improvised from this mac hint to work with Yosemite, and without hard-coding the adapter names. It's supposed to support growl, but I didn't check that part. I did, however, add OSX notification center support. Feel free to fork and fix any issues you encounter.

Most the credit for these changes go to Dave Holland.


  • Mac OSX 10+
  • Administrator privileges
gregorynicholas / Example.scpt
Created Oct 3, 2019 — forked from pudquick/Example.scpt
Make DMGs from folders
View Example.scpt
property destination_for_dmgs : "/Users/mike/Desktop"
on open the_items
repeat with an_item in the_items
set the_info to info for an_item
if kind of the_info is "Folder" then
set dmg_path to quoted form of (destination_for_dmgs & "/" & (name of the_info) & ".dmg")
set src_path to quoted form of POSIX path of an_item
set vol_name to quoted form of (name of the_info)
set command_str to "hdiutil create " & dmg_path & " -volname " & vol_name & " -srcfolder " & src_path
# Credit to frogor for the objc
from Foundation import NSBundle
import json
import objc
import os
import plistlib
import subprocess
View Three Wise

Date: [date]

Between us [company name] and you [customer name].


In short; neither of us will share any confidential information about each-other, by any means, with anyone else.

What’s confidential information?

gregorynicholas /
Created Sep 28, 2019 — forked from malarkey/
(Data) Protection Racket
View custom-properties-boilerplate.css
/* CSS Custom Properties */
:root {
--font-family: 'Georgia', serif;
--font-family-alt: 'Helvetica', Arial, sans-serif;
--font-weight: 400;
--font-weight-bold: 700;
--font-weight-black: 900;
/* 3:4 perfect fourth scale */
You can’t perform that action at this time.