Skip to content

Instantly share code, notes, and snippets.

View adamshand's full-sized avatar

Adam Shand adamshand

View GitHub Profile
@scollinson
scollinson / grabaseat.py
Created July 17, 2012 03:21
kiwicon grabaseat script
#!/usr/bin/env python
"""
Script to poll grabaseat.co.nz for cheap flights to and from conferences
Written by Sam Collinson (smc@affinity.net.nz) on 19/08/10
** Updated 17/07/12 with new URL
"""
import urllib, urllib2
from datetime import datetime, date
from sys import version_info
@albertbori
albertbori / Installation.md
Last active July 15, 2024 15:33
Automatically disable Wifi when an Ethernet connection (cable) is plugged in on a Mac

Overview

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.

Requirements

  • Mac OSX 10+
  • Administrator privileges
@brooksvb
brooksvb / Uptime-Kuma-Status-Page-Dark-Mode-High-Density-Tweaks.css
Last active June 27, 2024 21:01
These CSS tweaks are for higher density display for Uptime Kuma status pages in dark mode.
:root {
--min-item-width: 28ch;
--max-item-width: .5fr;
--grid-spacing: .25rem;
--item-padding: .25rem;
}
/* Let items expand on small screens */
@media (max-width: 600px) {
:root {
@marnixk
marnixk / pocketbase_stripe_utils.js
Created July 18, 2024 10:15
Pocketbase Stripe Javascript Functions
/*
____ _ _ _ _ _ _ _
/ ___|| |_ _ __(_)_ __ ___ | | | | |_(_) |___
\___ \| __| '__| | '_ \ / _ \ | | | | __| | / __|
___) | |_| | | | |_) | __/ | |_| | |_| | \__ \
|____/ \__|_| |_| .__/ \___| \___/ \__|_|_|___/
|_|
Purpose: