Skip to content

Instantly share code, notes, and snippets.

View neonichu's full-sized avatar
🤬
GitHub, cancel your contract with ICE!

Boris Bügling neonichu

🤬
GitHub, cancel your contract with ICE!
View GitHub Profile
@travisbrown
travisbrown / response-de-goes.md
Last active March 31, 2024 14:41
Response to cease and desist letter from John A. De Goes, CEO of Ziverge
@ryanpcmcquen
ryanpcmcquen / darkify_slack.sh
Last active February 23, 2023 16:08
Darkify your Slack.
#!/bin/sh
# Darkify Slack on Mac OS or Linux.
# curl https://gist.githubusercontent.com/ryanpcmcquen/8a7ddc72460eca0dc1f2dc389674dde1/raw/darkify_slack.sh | sh
if [ "`uname -s`" = "Darwin" ]; then
SLACK_INTEROP_JS="/Applications/Slack.app/Contents/Resources/app.asar.unpacked/dist/ssb-interop.bundle.js"
else
SLACK_INTEROP_JS="/usr/lib/slack/resources/app.asar.unpacked/dist/ssb-interop.bundle.js"
fi
@catlan
catlan / README.md
Last active May 10, 2024 15:04 — forked from zrxq/.lldbinit
Execute lldb command and open its output in Kaleidoscope diff

Diff output of two lldb commands

Setup

  1. Copy the contents of the last snippet (lldbinit) from the gist page, and paste into your .lldbinit file. This makes the ksdiff macro known inside lldb.
  2. Put file ksdiff.py in ~/.lldb/
  3. sudo pip install temp
  4. Restart Xcode debug session

Example

(lldb) ksdiff ;

name download_total
AFNetworking 61983241
Fabric 50998892
Crashlytics 49667729
SDWebImage 45471101
Alamofire 42097177
CocoaLumberjack 36071914
Bolts 35294870
FirebaseInstanceID 30277793
FirebaseAnalytics 30254593
@DougGregor
DougGregor / dynamic_member_lookup_environment.swift
Created May 2, 2018 16:59
Using Swift 4.2's @dynamicMemberLookup to expose environment variables
import Darwin
@dynamicMemberLookup
struct Environment {
subscript(dynamicMember name: String) -> String? {
get {
guard let value = getenv(name) else { return nil }
return String(validatingUTF8: value)
}
@jpsim
jpsim / jazzy_linux.md
Last active July 3, 2020 20:26
Jazzy Linux

Running jazzy from a fresh Ubuntu machine:

Create a brand new Ubuntu machine

$ doctl compute droplet create jazzy --size 16gb \
    --image ubuntu-16-10-x64 --region sfo1
$ doctl compute ssh jazzy

Install Swift

@helenvholmes
helenvholmes / best-books-2017.md
Last active December 14, 2017 14:44
I read a bunch o'stuff in 2k17 so your 2k18 will be *kisses fingers*

Of the books I've read this year here's my verdict on the ones worth (re-)reading:

Her Body and Other Parties, Carmen Maria Machado: A collection of short stories from Carmen Maria Machado. When trying to describe it to other people I've tried "fantastical horror while trying to describe the female experience" but I don't mean that with some sort of Stephen King IT connotation: all of the stories have a fantastical element to them, and they're worrisome, but they're not out-right terrifying. The only exception to this (for me in any case) was the third story that was basically a fanfiction of Law & Order SVU. Opinions in my book club were pretty split and many hated it but I found it to be the most haunting thing I've read all year.

Also, met the author in person and she seems pretty rad. Gifting this book to a few ladies in my life this year. [Plot](https://www.goodreads

class Function<B> {
func call<A>(_ a: A) -> B {
fatalError("unimplemented")
}
}
final class PrintInt: Function<Void> {
func call(_ a: Int) -> Void {
print(a)
}
As of iOS 11/macOS High Sierra, and only including ones in Foundation and CoreFoundation
Strings:
_NSCFString - a CFStringRef or CFMutableStringRef. This is the most common type of string object currently.
- May have 8 bit (ASCII) or 16 bit (UTF-16) backing store
_NSCFConstantString - a compile time constant CFStringRef, like you'd get with @"foo"
- May also be generated by dynamic string creation if matches a string in a pre-baked table of common strings called the StringROM
NSBigMutableString - an NSString backed by a CFStorage (https://github.com/opensource-apple/CF/blob/master/CFStorage.h) for faster handling of very large strings
NSCheapMutableString - a very limited NSMutableString that allows for zero-copy initialization. Used in NSFileManager for temporarily wrapping stack buffers.
@mikeash
mikeash / xcode.sh
Created September 15, 2017 17:07
Convince Xcode 9 not to smooth its source code font
#!/bin/bash
# Exit the script immediately on error
set -e
# We'll work in /tmp
cd /tmp
# Clone mach_override unless we already have it
if [ ! -d mach_override ]; then