作者 Anonymous [actionscript] 2012-01-26 12:33 (点击下载)

  1. # $Id: screen-keys.conf,v 1.6 2010/02/02 21:34:16 nicm Exp $
  2. #
  3. # By Nicholas Marriott. Public domain.
  4. #
  5. # This configuration file binds many of the common GNU screen key bindings to
  6. # appropriate tmux key bindings. Note that for some key bindings there is no
  7. # tmux analogue and also that this set omits binding some commands available in
  8. # tmux but not in screen.
  9. #
  10. # Note this is only a selection of key bindings and they are in addition to the
  11. # normal tmux key bindings. This is intended as an example not as to be used
  12. # as-is.
  13.  
  14. # Set the prefix to ^A.
  15. unbind C-b
  16. set -g prefix ^A
  17. bind a send-prefix
  18.  
  19. # Bind appropriate commands similar to screen.
  20. # lockscreen ^X x
  21. unbind ^X
  22. bind ^X lock-server
  23. unbind x
  24. bind x lock-server
  25.  
  26. # screen ^C c
  27. unbind ^C
  28. bind ^C new-window
  29. unbind c
  30. bind c new-window
  31.  
  32. # detach ^D d
  33. unbind ^D
  34. bind ^D detach
  35.  
  36. # displays *
  37. unbind *
  38. bind * list-clients
  39.  
  40. # next ^@ ^N sp n
  41. unbind ^@
  42. bind ^@ next-window
  43. unbind ^N
  44. bind ^N next-window
  45. unbind " "
  46. bind " " next-window
  47. unbind n
  48. bind n next-window
  49.  
  50. # title A
  51. unbind A
  52. bind A command-prompt "rename-window %%"
  53.  
  54. # other ^A
  55. unbind ^A
  56. bind ^A last-window
  57.  
  58. # prev ^H ^P p ^?
  59. unbind ^H
  60. bind ^H previous-window
  61. unbind ^P
  62. bind ^P previous-window
  63. unbind p
  64. bind p previous-window
  65. unbind BSpace
  66. bind BSpace previous-window
  67.  
  68. # windows ^W w
  69. unbind ^W
  70. bind ^W list-windows
  71. unbind w
  72. bind w list-windows
  73.  
  74. # quit
  75. unbind
  76. bind confirm-before "kill-server"
  77.  
  78. # kill K k
  79. unbind K
  80. bind K confirm-before "kill-window"
  81. unbind k
  82. bind k confirm-before "kill-window"
  83.  
  84. # redisplay ^L l
  85. unbind ^L
  86. bind ^L refresh-client
  87. unbind l
  88. bind l refresh-client
  89.  
  90. # split -v |
  91. unbind |
  92. bind | split-window -h
  93. unbind -
  94. bind - split-window -v
  95.  
  96. # " windowlist -b
  97. unbind '"'
  98. bind '"' choose-window
  99.  
  100. ########################################
  101.  
  102. set -g history-limit 8000
  103. set -g mouse-select-pane on
  104. set -g set-titles on
  105. set -g set-titles-string "[###S.#I #W] #T"
  106. set -g status-left ""
  107. set -g visual-bell on
  108. set -g status-right "#[bg=yellow,fg=black,bold] #(cut -d' ' -f1 /proc/loadavg)#[nobold] #(cut -d' ' -f2,3 /proc/loadavg) "
  109. setw -g window-status-current-format "#[bold,fg=white,bg=magenta][[#I:#W#F]]#[default]"
  110.  
  111. setw -g automatic-rename on
  112. setw -g aggressive-resize on
  113. setw -g mode-keys vi
  114. setw -g mode-mouse off
  115. setw -g monitor-activity on
  116. setw -g window-status-alert-attr reverse,bold
  117. setw -g alternate-screen on
  118. set -g utf8 on
  119. set -g mouse-utf8 on
  120.  
  121. set -g base-index 1
  122. bind '0' select-window -t 10
  123. # setw -g xterm-keys on
  124.  
  125.  
  126. bind-key b set-option status
  127. bind-key m command-prompt "split-window 'info %%'"
  128.  
  129. set -g update-environment "DISPLAY WINDOWID SSH_ASKPASS SSH_AUTH_SOCK SSH_AGENT_PID SSH_CONNECTION LANG XAUTHORITY XMODIFIERS XIM GTK_IM_MODULE QT_IM_MODULE DEPENDS"
  130.  
  131. # http://blog.oldworld.fr/index.php?post/2010/03/21/256-colors-terminal-with-tmux-and-urxvt
  132. set -g default-terminal "screen-256color"
  133.  

提交下面的校正或者修改. (点击这里开始一个新的帖子)
姓名: 在 cookie 中记住我的名字

屏幕抓图:(jpeg 或 png)