Env iterm2 macosx
- Open the iTerm2 menu
- Select Preferences
- On the "General" tab, select "Selection."
- Check "Applications in the terminal may access the clipboard."
need to run
brew install reattach-to-user-namespace
reference: https://www.jdeen.com/blog/tmux-on-macos-copy-to-system-clipboard