2012-08-22 5 views
8

저는 Tmux 사용자입니다. 설정이 여러 개인 .tmux.conf 파일이 있는데 파일을 원본으로 만들려고하면 오류가 발생합니다.Tmux .tmux.conf가 제대로로드되지 않습니다.

  • 알 수없는 옵션 : 창 기반 인덱스
  • 나쁜 값 :
  • 알 수없는 값에 : 센터
  • 내가 갖는

    ############ 
    # Settings # 
    ############ 
    # http://alexyu.se/content/2012/04/tmux-and-irssi-sitting-tree 
    
    # Define default shell 
    set -g default-command /bin/zsh 
    
    # Start numbering at 1 
    set -g base-index 1 
    setw -g pane-base-index 1 
    
    # Allows for faster key repetition 
    set -s escape-time 0 
    
    # Rather than constraining window size to the maximum size of any client 
    # connected to the *session*, constrain window size to the maximum size of any 
    # client connected to *that window*. Much more reasonable. 
    setw -g aggressive-resize on 
    
    # Activity monitoring 
    setw -g monitor-activity on 
    set -g visual-activity on 
    
    # Status bar configuration 
    set -g status-utf8 on 
    set -g status-justify center 
    set -g status-interval 60 
    set -g status-left-length 40 
    
    # Status bar data 
    set -g status-left "#[fg=green]Session: #S #[fg=yellow]#I #[fg=cyan]#P" 
    set -g status-right "#(~/battery Discharging) | #[fg=cyan]%d %b %R" 
    
    # Enable the mouse 
    setw -g mode-mouse on 
    set -g mouse-select-pane on 
    set -g mouse-resize-pane on 
    set -g mouse-select-window on 
    # setw -g mode-mouse off 
    
    # Settings tmux for 256 colors 
    set -g default-terminal "screen-256color" 
    
    # enable vi keys. 
    setw -g mode-keys vi 
    
    ################ 
    # Key bindings # 
    ################ 
    
    # C-b is not acceptable -- Vim uses it 
    set-option -g prefix C-a 
    unbind C-b 
    bind-key a last-window 
    
    # reload source file 
    bind r source-file ~/.tmux.conf \; display "Reloaded!" 
    
    # Allows us to use C-a a <command> to send commands 
    # to a TMUX session inside another TMUX session 
    bind-key C-a send-prefix 
    
    # Vertical and horizontal splitting 
    bind | split-window -h 
    bind - split-window -v 
    
    # Home row movement between panes 
    bind h select-pane -L 
    bind j select-pane -D 
    bind k select-pane -U 
    bind l select-pane -R 
    
    # Cycle through windows 
    bind -r C-h select-window -t :- 
    bind -r C-l select-window -t :+ 
    
    # Resizing Panes 
    bind -r H resize-pane -L 5 
    bind -r J resize-pane -D 5 
    bind -r K resize-pane -U 5 
    bind -r L resize-pane -R 5 
    
    # Open panes in the same directory using the tmux-panes script 
    unbind v 
    unbind h 
    bind v send-keys " ~/tmux-panes -h" C-m 
    bind h send-keys " ~/tmux-panes -v" C-m 
    
    # Maximize and restore a pane 
    unbind Up 
    bind Up new-window -d -n tmp \; swap-pane -s tmp.1 \; select-window -t tmp 
    unbind Down 
    bind Down last-window \; swap-pane -s tmp.1 \; kill-window -t tmp 
    
    # vi like keybindings 
    unbind [ 
    bind Escape copy-mode 
    unbind p 
    bind p paste-buffer 
    bind -t vi-copy 'v' begin-selection 
    bind -t vi-copy 'y' copy-selection 
    
    # copy and paste with system clipboard using xclip 
    bind C-c run "tmux save-buffer - | xclip -i -sel clipboard" 
    bind C-v run "tmux set-buffer \"$(xclip -o -sel clipboard)\"; tmux paste-buffer" 
    
    # Pipe the current pane to a log file with Shift-H - Press Shift-H again to stop. 
    bind-key H pipe-pane -o "cat >>$HOME/#W-tmux.log" \; display-message "Toggled logging to $HOME/#W-tmux.log" 
    
    # Sync panes - send what you're typing to other panes. 
    bind C-s set-window-option synchronize-panes 
    

    오류는이 있습니다

  • 값이 잘못되었습니다 : 60
  • 알 수없는 명령 : bind
  • 알 수없는 명령을 때어
  • 알 수없는 명령 : setw
  • 알 수없는 명령 : 문제는 문서 내부에 들어온다 눈에 보이지 않는 바이트했다
+0

어쩌면 그게 문제이지만 이상하게도 나는 보이지 않는 바이트가 무엇을 의미하는지 이해하지 못하고 ... – CrimsonKing

+0

그래, 그게 보이지 않는 바이트 인 것 같습니다. 해결 됐어. – CrimsonKing

+3

비슷한 문제가있는 사람은 이미 다른 tmux 세션이 열려 있으면 tmux가 새로운 tmux를 열 때 설정 파일을로드하지 않는다는 것을 알고 있어야합니다. "source-file ~/.tmux.conf"또는 "tmux source-file ~/.tmux.conf"를 호출 할 수 있습니다. –

답변

6

설정합니다. Vim에서 편집 할 때만 볼 수있었습니다. 감사.

관련 문제