tmux没有服务器在/ private / tmp / tmux-502 / default上运行

时间:2016-12-26 05:57:12

标签: macos tmux macos-sierra

在macOS 10.12.1上

tmux 2.3

运行时:

rescue in require'
            from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:144:in
  

收到错误:

tmux source-file ~/.tmux.conf

3 个答案:

答案 0 :(得分:5)

运行自动配置tmux工作区然后附加它们的脚本时,我遇到了同样的错误。

然而,当我单独运行tmux命令时,我得到了一个更有用的错误。它告诉我,~/.tmux.conf文件的几行导致了错误。我猜他们已经过时了。

我评论了这些线,现在一切正常。也许这对你也有用吗?

答案 1 :(得分:0)

您不得跑步

tmux source-file ~/.tmux.conf
  1. .tmix.conf在tmux服务器启动时自动启动。
  2. 如果需要使用其他Alternative.conf文件,则必须使用'-f'选项: tmux -f alternative.conf

  3. 如果需要运行源文件,看起来服务器必须首先启动(如果尚未启动): tmux start-server \; source-file source.tmux

答案 2 :(得分:-2)

I will use Iterm2 and brew

if you installed previously tmux please uninstall it, if you use brew with brew

brew uninstall tmux --force

then install it again

brew install tmux

and finally create a .tmux.conf file in your home directory

cd && cat > .tmux.conf                                                                                                                                                                                                                                                                            
set-option -g mouse on

# make scrolling with wheels work
bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'select-pane -t=; copy-mode -e; send-keys -M'"
bind -n WheelDownPane select-pane -t= \; send-keys -M

type Ctrl - d and thats all