Skip to content

Instantly share code, notes, and snippets.

View NSExceptional's full-sized avatar

Tanner Bennett NSExceptional

View GitHub Profile
@tom-go
tom-go / install_theos.sh
Created August 13, 2012 16:15
Theos install script
#!/bin/bash
export THEOS=/opt/theos
# clone theos.git
cd /opt
git clone git://github.com/DHowett/theos.git
# clone iphoneheaders.git
cd $THEOS
mv include include.bak
anonymous
anonymous / AppleWKHelper.ahk
Created December 15, 2012 12:28
AutoHotkey script from Billy TK Functions..: Make Apple Wireless Keyboard useful in MS Windows: - EJECT = Delete with repeat deleting on long pressing. Shift-DEL and other combinations works too. - Swap FN & left Control - FN-functions оn F3-F12 keys and arrow keys (use new-FN) - FN+EJECT = drive eject - F12 = INSERT (on your need, it simple to …
;
; AutoHotkey Version: 1.x
; Language.........: English
; Platform.........: NT/XP/Vista
; Author...........: mrBTK
;
; Script Function..: Make Apple Wireless Keyboard useful in MS Windows:
; - EJECT = Delete with repeat deleting on long pressing. Shift-DEL and other combinations works too.
; - Swap FN & left Control
; - FN-functions оn F3-F12 keys and arrow keys (use new-FN)
@nsdevaraj
nsdevaraj / UserInfo.xml
Last active September 21, 2020 22:18
Load Local XML info in Objective C, get the objects into a Dictionary
<Subjects>
<Subject name='Kannada' user="APPUSERIESKANNADA"/>
<Subject name='The Looney Tunes Show'>
<Topic code="looney" name="Looney" YTTV="true" />
<Topic code="619C868BD457387C" name="Baby Looney Tunes" />
<Topic code="6F2996C1B34A5FC4" name="The Looney Tunes Show" />
<Topic code="738A89379AF8DD2A" name="Bugs Bunny " />
<Topic code="A2C5018B54365C3C" name="Daffy Duck" />
<Topic code="D572048819F3CE24" name="Duck Dodgers" />
<Topic code="82C2B02BE527E534" name="Looney Tunes" />
@mattt
mattt / UIImageForSwatchOfColorWithSize.h
Created September 27, 2013 01:25
Create a UIImage swatch of a color with a specified size.
static UIImage * UIImageForSwatchOfColorWithSize(UIColor *color, CGSize size) {
UIImage *image = nil;
CGRect rect = CGRectMake(0.0f, 0.0f, size.width, size.height);
UIGraphicsBeginImageContext(rect.size);
{
CGContextRef c = UIGraphicsGetCurrentContext();
CGContextSetFillColorWithColor(c, [color CGColor]);
@steventroughtonsmith
steventroughtonsmith / gist:6763213
Created September 30, 2013 12:39
Non-opaque application windows in iOS 7, with optional blur. Shows the user's wallpaper under the app, with Parallax if supported.
typedef enum _UIBackgroundStyle {
UIBackgroundStyleDefault,
UIBackgroundStyleTransparent,
UIBackgroundStyleLightBlur,
UIBackgroundStyleDarkBlur,
UIBackgroundStyleDarkTranslucent
} UIBackgroundStyle;
@interface UIApplication (UIBackgroundStyle)
-(void)_setBackgroundStyle:(UIBackgroundStyle)style;
@FiloSottile
FiloSottile / 32.asm
Last active March 23, 2024 12:28
NASM Hello World for x86 and x86_64 Intel Mac OS X (get yourself an updated nasm with brew)
; /usr/local/bin/nasm -f macho 32.asm && ld -macosx_version_min 10.7.0 -o 32 32.o && ./32
global start
section .text
start:
push dword msg.len
push dword msg
push dword 1
mov eax, 4
@yannickl
yannickl / YLColor.swift
Last active September 16, 2023 03:55
Hex string <=> UIColor conversion in Swift
import Foundation
import UIKit
extension UIColor {
convenience init(hexString:String) {
let hexString:NSString = hexString.stringByTrimmingCharactersInSet(NSCharacterSet.whitespaceAndNewlineCharacterSet())
let scanner = NSScanner(string: hexString)
if (hexString.hasPrefix("#")) {
scanner.scanLocation = 1
@rmondello
rmondello / gist:b933231b1fcc83a7db0b
Last active April 5, 2024 07:10
Exporting (iCloud) Keychain and Safari credentials to a CSV file

Exporting (iCloud) Keychain and Safari credentials to a CSV file

Update (October 2021)

Exporting password + one-time code data from iCloud Keychain is now officially supported in macOS Monterey and Safari 15 (for Monterey, Big Sur, and Catalina). You can access it in the Password Manager’s “gear” icon (System Preferences > Passwords on Monterey, and Safari > Passwords everywhere else), or via the File > Export > Passwords... menu item). You shouldn't need to hack up your own exporter anymore.

Original, Obsolete Content (2014)

After my dad died, I wanted to be able to have access any of his online accounts going forward. My dad was a Safari user and used iCloud Keychain to sync his credentials across his devices. I don’t want to have to keep an OS X user account around just to access his accounts, so I wanted to export his credentials to a portable file.

@Pokechu22
Pokechu22 / Setting up MCP without a full MCP release.md
Last active March 31, 2024 21:35
Setting up MCP for newer versions (e.g. 1.12.2)

It's possible to use create an MCP installation for versions of Minecraft where there hasn't been a full MCP release. It takes a little bit of manual setup, but the end result is highly useful.

  1. Download and extract the most recent MCP build from http://www.modcoderpack.com/. (Currently, the latest build is http://www.modcoderpack.com/files/mcp940.zip)

  2. Edit version.cfg in the conf folder, and change ClientVersion and ServerVersion to the version you want (for instance, 1.12.2).

  3. Download the SRG zip for the version you want; these can generally be found at http://mcpbot.bspk.rs/mcp/<version>/mcp-<version>-srg.zip (for example, http://mcpbot.bspk.rs/mcp/1.11.2/mcp-1.11.2-srg.zip) or at http://files.minecraftforge.net/maven/de/oceanlabs/mcp/mcp/<version>/mcp-<version>-srg.zip (for example, http://files.minecraftforge.net/maven/de/oceanlabs/mcp/mcp/1.12.2/mcp-1.12.2-srg.zip). (For 1.12.1 and 1.12.2, only the minecraftforge link works)

  4. Extract that zip into the MCP conf folder, over

@arobb
arobb / sierra-virtualbox-install.md
Last active November 24, 2020 13:15
Install macOS Sierra in VirtualBox on macOS host

Step 1 (Creating a bootable macOS Sierra ISO for VirtualBox):

  1. hdiutil attach /Applications/Install\ macOS\ Sierra\ Public\ Beta.app/Contents/SharedSupport/InstallESD.dmg -noverify -nobrowse -mountpoint /Volumes/install_app
  2. hdiutil create -o /tmp/Sierra.cdr -size 7316m -layout SPUD -fs HFS+J
  3. hdiutil attach /tmp/Sierra.cdr.dmg -noverify -nobrowse -mountpoint /Volumes/install_build
  4. asr restore -source /Volumes/install_app/BaseSystem.dmg -target /Volumes/install_build -noprompt -noverify -erase
  5. rm /Volumes/OS\ X\ Base\ System/System/Installation/Packages
  6. cp -rp /Volumes/install_app/Packages /Volumes/OS\ X\ Base\ System/System/Installation/
  7. cp -rp /Volumes/install_app/BaseSystem.chunklist /Volumes/OS\ X\ Base\ System/BaseSystem.chunklist