Skip to content

Instantly share code, notes, and snippets.

View alimbada's full-sized avatar

Ammaar Limbada alimbada

View GitHub Profile
@bzerangue
bzerangue / mac-trim-support-non-apple-ssd.markdown
Created June 25, 2012 02:39
Enabling TRIM Support on Mac OS X with Non-Apple SSDs

How To: Enable TRIM with Non-Apple SSD

The guide breaks the process down into three steps, all performed via copying and pasting the code snippets through the terminal window. To launch a terminal window, open the Utilities folder inside the Applications folder and select terminal.

The first step makes a backup of the original IOAHCIBlockStorage file called IOAHCIBlockStorage.original. You will be prompted to enter in your system password when using the "sudo" command, since you are modifying system files. Copy and paste the code into the terminal window, a successful or uneventful response is a new blank terminal line.

sudo cp /System/Library/Extensions/IOAHCIFamily.kext/Contents/PlugIns/IOAHCIBlockStorage.kext/Contents/MacOS/IOAHCIBlockStorage /System/Library/Extensions/IOAHCIFamily.kext/Contents/PlugIns/IOAHCIBlockStorage.kext/Contents/MacOS/IOAHCIBlockStorage.original

Next the code patches the IOAHCIBlockStorage file, removing the requirements that the SSD be made by Apple. Copy and paste t

@bradwilson
bradwilson / gist:2229275
Created March 28, 2012 18:41
Scorch PowerShell script for mixed Git/TFS environments
& taskkill /f /im msbuild.exe
if ((get-gitstatus) -ne $null) {
& git clean -xdf -e *.suo -e packages/*
} else {
& tfpt scorch . /recursive /deletes /diff /noprompt /exclude:"*.suo,.\packages"
}