1214641f7SBram Moolenaar" Language: tmux(1) configuration file 2*2286304cSBram Moolenaar" Version: 3.2a (git-44ada9cd) 3214641f7SBram Moolenaar" URL: https://github.com/ericpruitt/tmux.vim/ 4214641f7SBram Moolenaar" Maintainer: Eric Pruitt <[email protected]> 5214641f7SBram Moolenaar" License: 2-Clause BSD (http://opensource.org/licenses/BSD-2-Clause) 6214641f7SBram Moolenaar 7036986f1SBram Moolenaarif exists("b:current_syntax") 8214641f7SBram Moolenaar finish 9214641f7SBram Moolenaarendif 10214641f7SBram Moolenaar 116c391a74SBram Moolenaar" Explicitly change compatibility options to Vim's defaults because this file 12036986f1SBram Moolenaar" uses line continuations. 13036986f1SBram Moolenaarlet s:original_cpo = &cpo 14214641f7SBram Moolenaarset cpo&vim 15214641f7SBram Moolenaar 16036986f1SBram Moolenaarlet b:current_syntax = "tmux" 170b0f0992SBram Moolenaarsyntax iskeyword @,48-57,_,192-255,- 18214641f7SBram Moolenaarsyntax case match 19214641f7SBram Moolenaar 20214641f7SBram Moolenaarsyn keyword tmuxAction none any current other 21214641f7SBram Moolenaarsyn keyword tmuxBoolean off on 22214641f7SBram Moolenaar 23214641f7SBram Moolenaarsyn keyword tmuxTodo FIXME NOTE TODO XXX contained 24214641f7SBram Moolenaar 25214641f7SBram Moolenaarsyn match tmuxColour /\<colour[0-9]\+/ display 26214641f7SBram Moolenaarsyn match tmuxKey /\(C-\|M-\|\^\)\+\S\+/ display 270b0f0992SBram Moolenaarsyn match tmuxNumber /\<\d\+\>/ display 28214641f7SBram Moolenaarsyn match tmuxFlags /\s-\a\+/ display 29214641f7SBram Moolenaarsyn match tmuxVariable /\w\+=/ display 30214641f7SBram Moolenaarsyn match tmuxVariableExpansion /\${\=\w\+}\=/ display 3191359014SBram Moolenaarsyn match tmuxControl /%\(if\|elif\|else\|endif\)/ 32214641f7SBram Moolenaar 33*2286304cSBram Moolenaarsyn region tmuxComment start=/#/ skip=/\\\@<!\\$/ end=/$/ contains=tmuxTodo,@Spell 34214641f7SBram Moolenaar 35*2286304cSBram Moolenaarsyn region tmuxString start=+"+ skip=+\\\\\|\\"\|\\$+ excludenl end=+"+ end='$' contains=tmuxFormatString,@Spell 36*2286304cSBram Moolenaarsyn region tmuxString start=+'+ skip=+\\\\\|\\'\|\\$+ excludenl end=+'+ end='$' contains=tmuxFormatString,@Spell 37214641f7SBram Moolenaar 38214641f7SBram Moolenaar" TODO: Figure out how escaping works inside of #(...) and #{...} blocks. 39214641f7SBram Moolenaarsyn region tmuxFormatString start=/#[#DFhHIPSTW]/ end=// contained keepend 40*2286304cSBram Moolenaarsyn region tmuxFormatString start=/#{/ skip=/#{.\{-}}/ end=/}/ keepend 41214641f7SBram Moolenaarsyn region tmuxFormatString start=/#(/ skip=/#(.\{-})/ end=/)/ contained keepend 42214641f7SBram Moolenaar 43214641f7SBram Moolenaarhi def link tmuxFormatString Identifier 44214641f7SBram Moolenaarhi def link tmuxAction Boolean 45214641f7SBram Moolenaarhi def link tmuxBoolean Boolean 46214641f7SBram Moolenaarhi def link tmuxCommands Keyword 4791359014SBram Moolenaarhi def link tmuxControl Keyword 48214641f7SBram Moolenaarhi def link tmuxComment Comment 49214641f7SBram Moolenaarhi def link tmuxKey Special 50214641f7SBram Moolenaarhi def link tmuxNumber Number 51214641f7SBram Moolenaarhi def link tmuxFlags Identifier 52214641f7SBram Moolenaarhi def link tmuxOptions Function 53214641f7SBram Moolenaarhi def link tmuxString String 54214641f7SBram Moolenaarhi def link tmuxTodo Todo 55214641f7SBram Moolenaarhi def link tmuxVariable Identifier 56214641f7SBram Moolenaarhi def link tmuxVariableExpansion Identifier 57214641f7SBram Moolenaar 58*2286304cSBram Moolenaar" Make the foreground of colourXXX keywords match the color they represent 59*2286304cSBram Moolenaar" when g:tmux_syntax_colors is unset or set to a non-zero value. 60214641f7SBram Moolenaar" Darker colors have their background set to white. 61*2286304cSBram Moolenaarif get(g:, "tmux_syntax_colors", 1) 62214641f7SBram Moolenaar for s:i in range(0, 255) 63214641f7SBram Moolenaar let s:bg = (!s:i || s:i == 16 || (s:i > 231 && s:i < 235)) ? 15 : "none" 64214641f7SBram Moolenaar exec "syn match tmuxColour" . s:i . " /\\<colour" . s:i . "\\>/ display" 65214641f7SBram Moolenaar\ " | highlight tmuxColour" . s:i . " ctermfg=" . s:i . " ctermbg=" . s:bg 66214641f7SBram Moolenaar endfor 67*2286304cSBram Moolenaarendif 68214641f7SBram Moolenaar 69214641f7SBram Moolenaarsyn keyword tmuxOptions 70*2286304cSBram Moolenaar\ backspace buffer-limit command-alias copy-command default-terminal editor 71*2286304cSBram Moolenaar\ escape-time exit-empty activity-action assume-paste-time base-index 72*2286304cSBram Moolenaar\ bell-action default-command default-shell default-size destroy-unattached 7391359014SBram Moolenaar\ detach-on-destroy display-panes-active-colour display-panes-colour 74*2286304cSBram Moolenaar\ display-panes-time display-time exit-unattached extended-keys focus-events 75*2286304cSBram Moolenaar\ history-file history-limit key-table lock-after-time lock-command 76*2286304cSBram Moolenaar\ message-command-style message-limit message-style aggressive-resize 77*2286304cSBram Moolenaar\ allow-rename alternate-screen automatic-rename automatic-rename-format 78*2286304cSBram Moolenaar\ clock-mode-colour clock-mode-style copy-mode-current-match-style 79*2286304cSBram Moolenaar\ copy-mode-mark-style copy-mode-match-style main-pane-height 80*2286304cSBram Moolenaar\ main-pane-width mode-keys mode-style monitor-activity monitor-bell 81*2286304cSBram Moolenaar\ monitor-silence mouse other-pane-height other-pane-width 82*2286304cSBram Moolenaar\ pane-active-border-style pane-base-index pane-border-format 83*2286304cSBram Moolenaar\ pane-border-lines pane-border-status pane-border-style pane-colours prefix 84*2286304cSBram Moolenaar\ prefix2 prompt-history-limit remain-on-exit renumber-windows repeat-time 85*2286304cSBram Moolenaar\ set-clipboard set-titles set-titles-string silence-action status status-bg 86*2286304cSBram Moolenaar\ status-fg status-format status-interval status-justify status-keys 87*2286304cSBram Moolenaar\ status-left status-left-length status-left-style status-position 88*2286304cSBram Moolenaar\ status-right status-right-length status-right-style status-style 89*2286304cSBram Moolenaar\ synchronize-panes terminal-features terminal-overrides update-environment 90*2286304cSBram Moolenaar\ user-keys visual-activity visual-bell visual-silence window-active-style 91*2286304cSBram Moolenaar\ window-size window-status-activity-style window-status-bell-style 9291359014SBram Moolenaar\ window-status-current-format window-status-current-style 9391359014SBram Moolenaar\ window-status-format window-status-last-style window-status-separator 94*2286304cSBram Moolenaar\ window-status-style window-style word-separators wrap-search 95214641f7SBram Moolenaar 96214641f7SBram Moolenaarsyn keyword tmuxCommands 970b0f0992SBram Moolenaar\ attach attach-session bind bind-key break-pane breakp capture-pane 980b0f0992SBram Moolenaar\ capturep choose-buffer choose-client choose-tree clear-history clearhist 99*2286304cSBram Moolenaar\ clock-mode command-prompt confirm confirm-before copy-mode customize-mode 100*2286304cSBram Moolenaar\ detach detach-client display display-menu display-message display-panes 101*2286304cSBram Moolenaar\ display-popup displayp find-window findw if if-shell join-pane joinp 102*2286304cSBram Moolenaar\ kill-pane kill-server kill-session kill-window killp has has-session killw 103*2286304cSBram Moolenaar\ link-window linkw list-buffers list-clients list-commands list-keys 104*2286304cSBram Moolenaar\ list-panes list-sessions list-windows load-buffer loadb lock lock-client 105*2286304cSBram Moolenaar\ lock-server lock-session lockc last-pane lastp locks ls last last-window 106*2286304cSBram Moolenaar\ lsb delete-buffer deleteb lsc lscm lsk lsp lsw menu move-pane move-window 107*2286304cSBram Moolenaar\ clear-prompt-history clearphist movep movew new new-session new-window 108*2286304cSBram Moolenaar\ neww next next-layout next-window nextl paste-buffer pasteb pipe-pane 109*2286304cSBram Moolenaar\ pipep popup prev previous-layout previous-window prevl refresh 110*2286304cSBram Moolenaar\ refresh-client rename rename-session rename-window renamew resize-pane 111*2286304cSBram Moolenaar\ resize-window resizep resizew respawn-pane respawn-window respawnp 112*2286304cSBram Moolenaar\ respawnw rotate-window rotatew run run-shell save-buffer saveb 11368e6560bSBram Moolenaar\ select-layout select-pane select-window selectl selectp selectw send 11468e6560bSBram Moolenaar\ send-keys send-prefix set set-buffer set-environment set-hook set-option 11568e6560bSBram Moolenaar\ set-window-option setb setenv setw show show-buffer show-environment 116*2286304cSBram Moolenaar\ show-hooks show-messages show-options show-prompt-history 117*2286304cSBram Moolenaar\ show-window-options showb showenv showmsgs showphist showw source 118*2286304cSBram Moolenaar\ source-file split-window splitw start start-server suspend-client suspendc 119*2286304cSBram Moolenaar\ swap-pane swap-window swapp swapw switch-client switchc unbind unbind-key 120*2286304cSBram Moolenaar\ unlink-window unlinkw wait wait-for 121214641f7SBram Moolenaar 122036986f1SBram Moolenaarlet &cpo = s:original_cpo 123036986f1SBram Moolenaarunlet! s:original_cpo s:bg s:i 124