sublimetext3 – 当我使用TMUX时,我无法在Sublime中打开文件夹

前端之家收集整理的这篇文章主要介绍了sublimetext3 – 当我使用TMUX时,我无法在Sublime中打开文件夹前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
操作系统:约塞米蒂
iterm2,zsh

当我运行“subl”时.在我的终端上,我可以打开文件夹,但如果我运行tmux和“subl project-folder”,则文件夹不会打开.

➜  ~  whereis subl
/usr/bin/subl

➜  ~  which subl
/usr/local/bin/subl

➜  ~  subl -v
Sublime Text Build 3083

➜  ~  cat .bashrc
export PATH=~/bin:/Users/olleh/bin:/Users/olleh/bin:/Users/olleh/.rbenv/shims:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin

➜  ~  cat .bash_profile
if which rbenv > /dev/null; then eval "$(rbenv init -)"; fi
export PATH="$HOME/.rbenv/bin:$PATH"
eval "$(rbenv init -)"
export PATH=/usr/local/node/bin:$PATH
export MANPATH=/usr/local/node/share/man:$MANPATH

➜  ~  ls -l /usr/local/bin/subl
lrwxr-xr-x  1 root  staff  62 Jul 13 09:51 /usr/local/bin/subl -> /Applications/Sublime Text.app/Contents/SharedSupport/bin/subl

tmux.conf

# Use vim keybindings in copy mode
set -g mode-mouse on
set -g mouse-resize-pane on
set -g mouse-select-pane on
set -g mouse-select-window on


# Setup 'v' to begin selection as in Vim

# Update default binding of `Enter` to also use copy-pipe

.zshrc

PATH=$PATH:/usr/local/bin/; export PATH

解决方法

好吧我明白了.这是因为Tmux没有对文件系统的root访问权限.

但是,您可以授予访问Tmux,https://github.com/ChrisJohnsen/tmux-MacOSX-pasteboard的权限.

这是步骤.

>安装此package.brew install reattach-to-user-namespace
>将此添加到〜/ .tmux.conf set-option -g default-command“reattach-to-user-namespace -l zsh”(根据您的shell更改zsh)

希望有所帮助.

原文链接:https://www.f2er.com/linux/393710.html

猜你在找的Linux相关文章