Skip to content

Instantly share code, notes, and snippets.

View dredhorse's full-sized avatar

Don Redhorse dredhorse

View GitHub Profile
@dredhorse
dredhorse / ChangeOpenFilesLimitMacOS.md
Last active March 19, 2021 16:32 — forked from tombigel/README.md
How to Change Open Files Limit on OS X and macOS Catalina (10.8 - 10.15)

How to Change Open Files Limit on OS X and macOS

_This is a shorter version without changing the limit.maxproc values derived from the original gist.

Please take a look at https://gist.github.com/tombigel/d503800a282fcadbee14b537735d202c before doing anything from this gist

I removed any explenation from this and I also removed the changes to limit.maxproc

#!/bin/sh
# Some things taken from here
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
# Set the colours you can use
black='\033[0;30m'
white='\033[0;37m'
red='\033[0;31m'
green='\033[0;32m'
@dredhorse
dredhorse / gist:4013405
Created November 4, 2012 20:04 — forked from Afforess/gist:4013360
Death Cause Factory pattern
public enum DeathCause implements DeathCauseFactory {
DROWNING {
public Cause<?> buildCause(Entity victim, Entity killer) {
return new DrowningCause(victim);
}
},
FALLING {
public Cause<?> buildCause(Entity victim, Entity killer) {
//TODO