yakirChen / macOS-libs

macOS Development Environment

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

macOS libs

Config Development Environment On macOS

工具编译安装

rwx

# r 4
# w 2
# x 1
chmod 111 rwx
# ---x--x--x  1 yakir  staff     0B 10 28 18:02 rwx
chmod 333 rwx
# --wx-wx-wx  1 yakir  staff     0B 10 28 18:02 rwx
chmod 555 rwx
# -r-xr-xr-x  1 yakir  staff     0B 10 28 18:02 rwx
chmod 755 rwx
# -rwxr-xr-x  1 yakir  staff     0B 10 28 18:02 rwx
chmod 777 rwx
# -rwxrwxrwx  1 yakir  staff     0B 10 28 18:02 rwx

自签名证书生成 & Nginx开启 h2、ssl

自签名证书生成 & Nginx开启 h2、ssl

Soft Links

ln -s /Volumes/To/repos/m2 ${HOME}/.m2 
ln -s /Volumes/To/repos/vscode ${HOME}/.vscode
ln -s "${HOME}/Library/Mobile Documents/com~apple~CloudDocs/Developer/macOS-libs/npmrc" ${HOME}/.npmrc
ln -s "${HOME}/Library/Mobile Documents/com~apple~CloudDocs/Developer/macOS-libs/tm_properties" ${HOME}/.tm_properties
ln -s "${HOME}/Library/Mobile Documents/com~apple~CloudDocs/Developer/macOS-libs/vim/vimrc" ${HOME}/.vimrc
ln -s "${HOME}/Library/Mobile Documents/com~apple~CloudDocs/Developer/macOS-libs/yarnrc" ${HOME}/.yarnrc
ln -s "${HOME}/Library/Mobile Documents/com~apple~CloudDocs/Developer/macOS-libs/zshrc" ${HOME}/.zshrc
rm ${HOME}/Library/Application\ Support/Code/User/settings.json
rm ${HOME}/Library/Application\ Support/Code/User/keybindings.json
ln -s /Users/yakir/Library/Mobile\ Documents/com\~apple\~CloudDocs/Developer/macOS-libs/vscode/vscode-settings.json ${HOME}/Library/Application\ Support/Code/User/settings.json
ln -s /Users/yakir/Library/Mobile\ Documents/com\~apple\~CloudDocs/Developer/macOS-libs/vscode/vscode-keybindings.json ${HOME}/Library/Application\ Support/Code/User/keybindings.json

Too many open files

sudo cp "/Users/yakir/Library/Mobile Documents/com~apple~CloudDocs/Developer/macOS-libs/macOS-limit/limit.maxfiles.plist" /Library/LaunchDaemons/
sudo cp "/Users/yakir/Library/Mobile Documents/com~apple~CloudDocs/Developer/macOS-libs/macOS-limit/limit.maxproc.plist" /Library/LaunchDaemons/

sudo chown root:wheel /Library/LaunchDaemons/limit.maxfiles.plist
sudo chown root:wheel /Library/LaunchDaemons/limit.maxproc.plist

sudo launchctl load -w /Library/LaunchDaemons/limit.maxfiles.plist
sudo launchctl load -w /Library/LaunchDaemons/limit.maxproc.plist
sudo vim /etc/sysctl.conf
sudo vim /etc/launchd.conf

sysctl -A | grep kern.max
kern.maxvnodes: 600000
kern.maxproc: 10000
kern.maxfiles: 300000
kern.maxfilesperproc: 300000
kern.maxprocperuid: 7500
kern.maxnbuf: 16384

launchctl limit
	cpu         unlimited      unlimited
	filesize    unlimited      unlimited
	data        unlimited      unlimited
	stack       8388608        67104768
	core        0              unlimited
	rss         unlimited      unlimited
	memlock     unlimited      unlimited
	maxproc     7500           10000
	maxfiles    256            unlimited

macOS 高性能模式(performance mode)

😀

About

macOS Development Environment

License:Mozilla Public License 2.0


Languages

Language:Shell 94.8%Language:Vim Script 4.2%Language:CSS 1.0%