Skip to content

Instantly share code, notes, and snippets.

View ddamico's full-sized avatar

David D'Amico ddamico

View GitHub Profile
@jessfraz
jessfraz / boxstarter.ps1
Last active July 7, 2024 22:46
Boxstarter Commands for a new Windows box.
# Description: Boxstarter Script
# Author: Jess Frazelle <jess@linux.com>
# Last Updated: 2017-09-11
#
# Install boxstarter:
# . { iwr -useb http://boxstarter.org/bootstrapper.ps1 } | iex; get-boxstarter -Force
#
# You might need to set: Set-ExecutionPolicy RemoteSigned
#
# Run this boxstarter by calling the following from an **elevated** command-prompt:
@someoneAnyone
someoneAnyone / GlucoseWithUnitConcentrationMass.swift
Last active March 16, 2021 10:03
Glucose Value Conversion on iOS 10
//: # Glucose Value Conversion on iOS 10.
import Foundation // iOS 10.0, wathOS 3.0, macOS 10.12
/*:
****
## Current Nightscouter Implmentation
- Note: The current app treats glucose values as an aliased Double.
@Vestride
Vestride / encoding-video.md
Last active June 5, 2024 14:38
Encoding video for the web

Encoding Video

Installing

Install FFmpeg with homebrew. You'll need to install it with a couple flags for webm and the AAC audio codec.

brew install ffmpeg --with-libvpx --with-libvorbis --with-fdk-aac --with-opus
import Foundation
func BuildError(val: Int, msg: String) -> NSError { return NSError() }
func Error<T>(errorPointer: NSErrorPointer, val: Int, msg: String) -> T? {
if errorPointer != nil {
errorPointer.memory = BuildError(val, msg)
}
return nil
}
@darkseed
darkseed / Reachability.h
Created August 30, 2011 23:16 — forked from dhoerl/Reachability.h
Reachability (iOS) ARCified
/*
File: Reachability.h
Abstract: Basic demonstration of how to use the SystemConfiguration Reachablity APIs.
Version: 2.2 - ARCified
Disclaimer: IMPORTANT: This Apple software is supplied to you by Apple Inc.
("Apple") in consideration of your agreement to the following terms, and your
use, installation, modification or redistribution of this Apple software
@mxcl
mxcl / uninstall_homebrew.sh
Created August 26, 2011 11:25
Uninstall Homebrew
#!/bin/sh
# Just copy and paste the lines below (all at once, it won't work line by line!)
# MAKE SURE YOU ARE HAPPY WITH WHAT IT DOES FIRST! THERE IS NO WARRANTY!
function abort {
echo "$1"
exit 1
}
set -e