Created
July 14, 2021 00:25
-
-
Save e0da/5a784811549e059e8fd262d8c091819d to your computer and use it in GitHub Desktop.
Expand ulimit on bash login
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Add to .bash_profile to prevent processes from running out of file handles | |
# Limit determined by guess and check on macOS 10.15.7 Catalina | |
if uname | grep -q Darwin; then | |
# ulimit -n is OK because we already confirmed it's macOS | |
# shellcheck disable=SC2039 | |
ulimit -n "${ULIMIT_N:-49152}" | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment